diff options
author | remi durand <remi-j.durand@thalesgroup.com> | 2021-05-29 01:27:31 +0300 |
---|---|---|
committer | remi durand <remi-j.durand@thalesgroup.com> | 2021-05-29 01:30:34 +0300 |
commit | 370e9ca7415483641b95d64b8b5ebbc007406198 (patch) | |
tree | 931969a1982dc6812171a793e0666a59584bd19f /src/slic3r/GUI/Tab.cpp | |
parent | 7851f6e8751b9d293c8a8e1716ee7b17e432b275 (diff) |
fix search bar
Diffstat (limited to 'src/slic3r/GUI/Tab.cpp')
-rw-r--r-- | src/slic3r/GUI/Tab.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/slic3r/GUI/Tab.cpp b/src/slic3r/GUI/Tab.cpp index ba528684a..d7011117b 100644 --- a/src/slic3r/GUI/Tab.cpp +++ b/src/slic3r/GUI/Tab.cpp @@ -48,6 +48,7 @@ #include "PhysicalPrinterDialog.hpp" #include "UnsavedChangesDialog.hpp" #include "SavePresetDialog.hpp" +#include "Search.hpp" #ifdef WIN32 #include <commctrl.h> @@ -1771,6 +1772,7 @@ bool Tab::create_pages(std::string setting_type_name, int idx_page) if (current_group->sidetext_width >= 0) option.opt.sidetext_width = current_group->sidetext_width; + bool need_to_notified_search = false; bool colored = false; wxString label_path; for (int i = 1; i < params.size() - 1; i++) { @@ -1789,10 +1791,12 @@ bool Tab::create_pages(std::string setting_type_name, int idx_page) else if (params[i] == "full_label") { option.opt.label = option.opt.full_label; + need_to_notified_search = true; } else if (params[i].find("label$") != std::string::npos) { option.opt.label = params[i].substr(6, params[i].size() - 6); + need_to_notified_search = true; } else if (boost::starts_with(params[i], "label_width$")) { option.opt.label_width = atoi(params[i].substr(12, params[i].size() - 12).c_str()); @@ -1822,6 +1826,9 @@ bool Tab::create_pages(std::string setting_type_name, int idx_page) } } + if (need_to_notified_search) + Search::OptionsSearcher::register_label_override(option.opt.opt_key, option.opt.label, option.opt.full_label, option.opt.tooltip); + if(height>0) option.opt.height = height; |