summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2017-03-13 16:14:04 +0100
committerGitHub <noreply@github.com>2017-03-13 16:14:04 +0100
commitbde0c2e03ea2393b05f93e7311908ba6ebcb5c98 (patch)
tree83f6365467e13faca4e86bda719af2c9b8e91aa1
parentaf550e2f9822dc4ea7c06aee7d8b4f1af1d61de3 (diff)
parenta2776af67258a2016777843aae1156af339e72e8 (diff)
Merge pull request #8019 from Hinsbart/dim_fix
WindowDialog: Fix crash when running as ProjectManager
-rw-r--r--scene/gui/dialogs.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/scene/gui/dialogs.cpp b/scene/gui/dialogs.cpp
index 89008b56bf..a58e62f061 100644
--- a/scene/gui/dialogs.cpp
+++ b/scene/gui/dialogs.cpp
@@ -205,11 +205,11 @@ void WindowDialog::_notification(int p_what) {
} break;
#ifdef TOOLS_ENABLED
case NOTIFICATION_POST_POPUP: {
- if (get_tree() && get_tree()->is_editor_hint())
+ if (get_tree() && get_tree()->is_editor_hint() && EditorNode::get_singleton())
EditorNode::get_singleton()->dim_editor(true);
} break;
case NOTIFICATION_POPUP_HIDE: {
- if (get_tree() && get_tree()->is_editor_hint())
+ if (get_tree() && get_tree()->is_editor_hint() && EditorNode::get_singleton())
EditorNode::get_singleton()->dim_editor(false);
} break;
#endif