summaryrefslogtreecommitdiff
path: root/main/main.cpp
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2018-09-10 14:53:31 +0200
committerRémi Verschelde <rverschelde@gmail.com>2018-09-10 14:53:45 +0200
commitc0df3b147e59199fa3d7743f89c167a440daa070 (patch)
treee1af9a34c458938b3cf87828ede885a76277bef8 /main/main.cpp
parent0f6803ea779d46daeedcefa18d9d257fd661a86b (diff)
Make sure project manager gets editor hint set
Previous fix in e8e06b2 worked in most cases but not if you run e.g. 'godot -', where the '-' argument would mean that 'project_manager' is false and yet that's what will be opened eventually.
Diffstat (limited to 'main/main.cpp')
-rw-r--r--main/main.cpp5
1 files changed, 1 insertions, 4 deletions
diff --git a/main/main.cpp b/main/main.cpp
index a50a8827cd..96d00be737 100644
--- a/main/main.cpp
+++ b/main/main.cpp
@@ -792,10 +792,6 @@ Error Main::setup(const char *execpath, int argc, char *argv[], bool p_second_ph
// Determine if the project manager should be requested
project_manager = main_args.size() == 0 && !found_project;
}
-
- if (project_manager) {
- Engine::get_singleton()->set_editor_hint(true);
- }
#endif
if (main_args.size() == 0 && String(GLOBAL_DEF("application/run/main_scene", "")) == "") {
@@ -1697,6 +1693,7 @@ bool Main::start() {
#ifdef TOOLS_ENABLED
if (project_manager || (script == "" && test == "" && game_path == "" && !editor)) {
+ Engine::get_singleton()->set_editor_hint(true);
ProjectManager *pmanager = memnew(ProjectManager);
ProgressDialog *progress_dialog = memnew(ProgressDialog);
pmanager->add_child(progress_dialog);