Tidy fix for flicker in fullscreen mode when switching windows