feat(canvas): implement popup registry for enhanced menu management

- Introduced a new `PopupRegistry` class to manage persistent popups, improving the organization and lifecycle handling of popups within the canvas.
- Added `canvas_menu.cc` and `canvas_menu.h` to define menu item and section structures, along with rendering functions for a more declarative menu system.
- Updated `canvas.cc` to utilize the new popup registry, ensuring backward compatibility with legacy popup handling during the migration phase.

Benefits:
- Streamlines popup management, enhancing usability and maintainability of the canvas UI.
- Facilitates the addition of complex menu structures and interactions, improving overall user experience.
This commit is contained in:
scawful
2025-10-16 19:11:05 -04:00
parent bc9d8912bf
commit 99b0a7e11f
7 changed files with 643 additions and 22 deletions

View File

@@ -32,8 +32,10 @@ set(CANVAS_SRC
app/gui/canvas/canvas_geometry.cc
app/gui/canvas/canvas_interaction.cc
app/gui/canvas/canvas_interaction_handler.cc
app/gui/canvas/canvas_menu.cc
app/gui/canvas/canvas_modals.cc
app/gui/canvas/canvas_performance_integration.cc
app/gui/canvas/canvas_popup.cc
app/gui/canvas/canvas_rendering.cc
app/gui/canvas/canvas_usage_tracker.cc
app/gui/canvas/canvas_utils.cc