summaryrefslogtreecommitdiffhomepage
path: root/editor/imgui.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'editor/imgui.cpp')
-rw-r--r--editor/imgui.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/editor/imgui.cpp b/editor/imgui.cpp
index 1e7f8d4e..62479aaa 100644
--- a/editor/imgui.cpp
+++ b/editor/imgui.cpp
@@ -185,4 +185,13 @@ void app::draw_editor_pane(float main_menu_height)
}
}
+void app::do_escape()
+{
+ if (auto* ed = _editor.current_scenery_editor())
+ ed->clear_selection();
+ if (auto* ed = _editor.current_tile_editor())
+ ed->clear_selection();
+ ImGui::FocusWindow(nullptr);
+}
+
} // namespace floormat