1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-15 13:51:40 +00:00

Add editor setting to keep bottom panel state on play and stop game

This commit is contained in:
Hilderin
2024-04-22 19:22:06 -04:00
parent 7abe0c6014
commit 76205d4276
6 changed files with 29 additions and 19 deletions

View File

@@ -4391,17 +4391,19 @@ void EditorNode::_project_run_started() {
log->clear();
}
if (bool(EDITOR_GET("run/output/always_open_output_on_play"))) {
int action_on_play = EDITOR_GET("run/bottom_panel/action_on_play");
if (action_on_play == ACTION_ON_PLAY_OPEN_OUTPUT) {
bottom_panel->make_item_visible(log);
} else if (action_on_play == ACTION_ON_PLAY_OPEN_DEBUGGER) {
bottom_panel->make_item_visible(EditorDebuggerNode::get_singleton());
}
}
void EditorNode::_project_run_stopped() {
if (!bool(EDITOR_GET("run/output/always_close_output_on_stop"))) {
return;
int action_on_stop = EDITOR_GET("run/bottom_panel/action_on_stop");
if (action_on_stop == ACTION_ON_STOP_CLOSE_BUTTOM_PANEL) {
bottom_panel->hide_bottom_panel();
}
bottom_panel->make_item_visible(log, false);
}
void EditorNode::notify_all_debug_sessions_exited() {