Workaround window corruption on startup