feat(main_menu): add exit button and refactor layout with ColumnLayout

- Add `should_close_window()` method to force window close from UI.
- Replace standalone button with ColumnLayout for proper centering.
- Add "Exit" button that calls `should_close_window()`.
- Update ESC key handling to only close window when game is not running.
- Fix ColumnLayout to respect parent's anchor instead of hardcoded TOP_LEFT.
- Remove unused parameter name in Image::update for consistency.
This commit is contained in:
2026-07-13 18:15:34 +08:00
parent e7082bdbe0
commit acb0b94d7b
5 changed files with 45 additions and 19 deletions

View File

@@ -32,6 +32,8 @@ public:
void set_game_running(bool running);
void should_close_window();
private:
bool m_mouse_enable = false;
bool m_imgui_init = false;