diff options
author | mbalint12 <gameshow841@gmail.com> | 2017-02-06 17:50:01 +0100 |
---|---|---|
committer | mbalint12 <gameshow841@gmail.com> | 2017-02-06 18:17:20 +0100 |
commit | 1bd1af776c111f1efdd9a3b0259d8f916c052ef2 (patch) | |
tree | 62e8a9b4ceaa348e4b485f2c077cbe63a815c3ff /tools/editor | |
parent | af3fabeb7745e6f7f4e7fe7a299bdd234fff26a6 (diff) |
Add editor option for automatically closing the output when stopping the game.
Diffstat (limited to 'tools/editor')
-rw-r--r-- | tools/editor/editor_node.cpp | 8 | ||||
-rw-r--r-- | tools/editor/editor_settings.cpp | 1 |
2 files changed, 9 insertions, 0 deletions
diff --git a/tools/editor/editor_node.cpp b/tools/editor/editor_node.cpp index f8540e3c68..a31d62372c 100644 --- a/tools/editor/editor_node.cpp +++ b/tools/editor/editor_node.cpp @@ -2599,6 +2599,14 @@ void EditorNode::_menu_option_confirm(int p_option,bool p_confirmed) { play_custom_scene_button->set_pressed(false); play_custom_scene_button->set_icon(gui_base->get_icon("PlayCustom","EditorIcons")); //pause_button->set_pressed(false); + if (bool(EDITOR_DEF("run/output/always_close_output_on_stop", true))) { + for(int i=0;i<bottom_panel_items.size();i++) { + if (bottom_panel_items[i].control==log) { + _bottom_panel_switch(false,i); + break; + } + } + } emit_signal("stop_pressed"); } break; diff --git a/tools/editor/editor_settings.cpp b/tools/editor/editor_settings.cpp index 1cdc426541..ebac77699a 100644 --- a/tools/editor/editor_settings.cpp +++ b/tools/editor/editor_settings.cpp @@ -655,6 +655,7 @@ void EditorSettings::_load_defaults(Ref<ConfigFile> p_extra_config) { set("run/auto_save/save_before_running",true); set("run/output/always_clear_output_on_play",true); set("run/output/always_open_output_on_play",true); + set("run/output/always_close_output_on_stop",false); set("filesystem/resources/save_compressed_resources",true); set("filesystem/resources/auto_reload_modified_images",true); |