From fc181726b939b118a13098ba551ed18d8c87e90a Mon Sep 17 00:00:00 2001 From: Sander Speetjens Date: Sat, 7 Sep 2024 15:48:35 +0200 Subject: [PATCH] UI Move ui item stubs from header to src --- src/UI/UI_item.cpp | 13 ++++++++++++- src/UI/UI_item.hpp | 12 +++--------- 2 files changed, 15 insertions(+), 10 deletions(-) diff --git a/src/UI/UI_item.cpp b/src/UI/UI_item.cpp index c209fbf..ce0d5f1 100644 --- a/src/UI/UI_item.cpp +++ b/src/UI/UI_item.cpp @@ -137,4 +137,15 @@ json UI_item::to_json() const j["enabled"] = enabled; j["visible"] = visible; return j; -} \ No newline at end of file +} + +void UI_item::click() const {}; + +void UI_item::set_selected(std::string selected) +{ + UNUSED(selected); +}; +void UI_item::set_value(double value) +{ + UNUSED(value); +}; \ No newline at end of file diff --git a/src/UI/UI_item.hpp b/src/UI/UI_item.hpp index 6695cda..6505063 100644 --- a/src/UI/UI_item.hpp +++ b/src/UI/UI_item.hpp @@ -42,15 +42,9 @@ class UI_item virtual json to_json() const; - virtual void click() const {}; - virtual void set_selected(std::string selected) - { - UNUSED(selected); - }; - virtual void set_value(double value) - { - UNUSED(value); - }; + virtual void click() const; + virtual void set_selected(std::string selected); + virtual void set_value(double value); protected: std::string m_id;