getWindow and hasFocus from Gui class can be const