summaryrefslogtreecommitdiff
path: root/tools/editor/plugins/script_editor_plugin.cpp
diff options
context:
space:
mode:
authorRémi Verschelde <remi@verschelde.fr>2015-12-12 14:10:12 +0100
committerRémi Verschelde <remi@verschelde.fr>2015-12-12 14:10:12 +0100
commitc3db5d951c1ee938a0c789c78a9bb8045ef8605b (patch)
treecf0b5d127152dd6c52940810081992efc86f5f5f /tools/editor/plugins/script_editor_plugin.cpp
parenta73cf7f79447480b59ac15c9461a2664ac4bc34f (diff)
parent4d644ca997befb9b4607f8a3a21463ec2e599a00 (diff)
Merge pull request #3043 from TheHX/pr-script-debugger
Script debugger remains visible when using Debug->Show Debugger
Diffstat (limited to 'tools/editor/plugins/script_editor_plugin.cpp')
-rw-r--r--tools/editor/plugins/script_editor_plugin.cpp7
1 files changed, 2 insertions, 5 deletions
diff --git a/tools/editor/plugins/script_editor_plugin.cpp b/tools/editor/plugins/script_editor_plugin.cpp
index 37f4076a0c..c96616b42c 100644
--- a/tools/editor/plugins/script_editor_plugin.cpp
+++ b/tools/editor/plugins/script_editor_plugin.cpp
@@ -605,6 +605,7 @@ void ScriptEditor::_show_debugger(bool p_show) {
debug_menu->get_popup()->set_item_checked( debug_menu->get_popup()->get_item_index(DEBUG_SHOW), p_show);
+ debugger->set_always_visible(p_show);
}
void ScriptEditor::_script_created(Ref<Script> p_script) {
@@ -1338,11 +1339,7 @@ void ScriptEditor::_menu_option(int p_option) {
case DEBUG_SHOW: {
if (debugger) {
bool visible = debug_menu->get_popup()->is_item_checked( debug_menu->get_popup()->get_item_index(DEBUG_SHOW) );
- debug_menu->get_popup()->set_item_checked( debug_menu->get_popup()->get_item_index(DEBUG_SHOW), !visible);
- if (visible)
- debugger->hide();
- else
- debugger->show();
+ _show_debugger(!visible);
}
} break;
case HELP_CONTEXTUAL: {