From 189736c1a96a1ad0e571ad69f01039e96455011a Mon Sep 17 00:00:00 2001 From: dec05eba Date: Sat, 22 Feb 2025 13:31:51 +0100 Subject: Add option to take a screenshot (default hotkey: alt+f1) --- src/gui/DropdownButton.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'src/gui/DropdownButton.cpp') diff --git a/src/gui/DropdownButton.cpp b/src/gui/DropdownButton.cpp index 81bc015..bdc4027 100644 --- a/src/gui/DropdownButton.cpp +++ b/src/gui/DropdownButton.cpp @@ -201,6 +201,15 @@ namespace gsr { } } + void DropdownButton::set_item_description(const std::string &id, const std::string &new_description) { + for(auto &item : items) { + if(item.id == id) { + item.description_text.set_string(new_description); + return; + } + } + } + void DropdownButton::set_description(std::string description_text) { description.set_string(std::move(description_text)); } -- cgit v1.2.3-70-g09d2