Could store runtime.getWindow to a variable for reuse.