diff options
author | zaaarf <me@zaaarf.foo> | 2023-12-10 23:15:41 +0100 |
---|---|---|
committer | zaaarf <me@zaaarf.foo> | 2023-12-10 23:15:41 +0100 |
commit | 4ef33d4df6198e613b0f27406d49978c8ea2fb97 (patch) | |
tree | 7f07835485b877f3c01c52c188892499e5812f9b /src/openvic-simulation/interface/GUI.cpp | |
parent | 1eb28bd4fb959b69a30013f6438f0257a2ee7b03 (diff) |
feat: improved identifier registry macro
Diffstat (limited to 'src/openvic-simulation/interface/GUI.cpp')
-rw-r--r-- | src/openvic-simulation/interface/GUI.cpp | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/openvic-simulation/interface/GUI.cpp b/src/openvic-simulation/interface/GUI.cpp index 61b8683..244909e 100644 --- a/src/openvic-simulation/interface/GUI.cpp +++ b/src/openvic-simulation/interface/GUI.cpp @@ -42,11 +42,9 @@ bool Element::_fill_elements_key_map( return ret; } -Scene::Scene() : elements { "scene elements" } {} - bool Scene::_fill_key_map(NodeTools::key_map_t& key_map, UIManager const& ui_manager) { return Element::_fill_elements_key_map(key_map, [this](std::unique_ptr<Element>&& element) -> bool { - return elements.add_item(std::move(element)); + return scene_elements.add_item(std::move(element)); }, ui_manager); } @@ -59,11 +57,11 @@ node_callback_t Scene::expect_scene( }, ui_manager); } -Window::Window() : elements { "window elements" }, size {}, moveable { false }, fullscreen { false } {} +Window::Window() : moveable { false }, fullscreen { false } {} bool Window::_fill_key_map(NodeTools::key_map_t& key_map, UIManager const& ui_manager) { bool ret = Element::_fill_elements_key_map(key_map, [this](std::unique_ptr<Element>&& element) -> bool { - return elements.add_item(std::move(element)); + return window_elements.add_item(std::move(element)); }, ui_manager); ret &= Element::_fill_key_map(key_map, ui_manager); ret &= add_key_map_entries(key_map, |