Fix debugger focus stealing

At least on Windows, the authorization must be given every time, not only at startup.
This commit is contained in:
Pedro J. Estébanez
2018-05-28 21:49:48 +02:00
parent 4a98b1575b
commit 2fcbf9dd81
3 changed files with 15 additions and 4 deletions

View File

@ -726,6 +726,7 @@ Error Main::setup(const char *execpath, int argc, char *argv[], bool p_second_ph
memdelete(sdr);
} else {
script_debugger = sdr;
sdr->set_allow_focus_steal_pid(allow_focus_steal_pid);
}
} else if (debug_mode == "local") {
@ -1188,10 +1189,6 @@ Error Main::setup2(Thread::ID p_main_tid_override) {
#endif
if (allow_focus_steal_pid) {
OS::get_singleton()->enable_for_stealing_focus(allow_focus_steal_pid);
}
MAIN_PRINT("Main: Load Modules, Physics, Drivers, Scripts");
register_platform_apis();