mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-06 22:47:32 -06:00
Match style of checkboxes on Material Settings > Setting Overrides (#9551)
init
This commit is contained in:
parent
4925f65fed
commit
241d097d2e
2 changed files with 4 additions and 6 deletions
|
@ -3167,11 +3167,8 @@ void TabFilament::add_filament_overrides_page()
|
||||||
line = optgroup->create_single_option_line(optgroup->get_option(opt_key));
|
line = optgroup->create_single_option_line(optgroup->get_option(opt_key));
|
||||||
|
|
||||||
line.near_label_widget = [this, optgroup_wk = ConfigOptionsGroupWkp(optgroup), opt_key, opt_index](wxWindow* parent) {
|
line.near_label_widget = [this, optgroup_wk = ConfigOptionsGroupWkp(optgroup), opt_key, opt_index](wxWindow* parent) {
|
||||||
wxCheckBox* check_box = new wxCheckBox(parent, wxID_ANY, "");
|
auto check_box = new ::CheckBox(parent); // ORCA modernize checkboxes
|
||||||
|
check_box->Bind(wxEVT_TOGGLEBUTTON, [this, optgroup_wk, opt_key, opt_index](wxCommandEvent& evt) {
|
||||||
check_box->Bind(
|
|
||||||
wxEVT_CHECKBOX,
|
|
||||||
[this, optgroup_wk, opt_key, opt_index](wxCommandEvent& evt) {
|
|
||||||
const bool is_checked = evt.IsChecked();
|
const bool is_checked = evt.IsChecked();
|
||||||
if (auto optgroup_sh = optgroup_wk.lock(); optgroup_sh) {
|
if (auto optgroup_sh = optgroup_wk.lock(); optgroup_sh) {
|
||||||
if (Field *field = optgroup_sh->get_fieldc(opt_key, opt_index); field != nullptr) {
|
if (Field *field = optgroup_sh->get_fieldc(opt_key, opt_index); field != nullptr) {
|
||||||
|
|
|
@ -40,6 +40,7 @@
|
||||||
#include "ParamsPanel.hpp"
|
#include "ParamsPanel.hpp"
|
||||||
#include "Widgets/RoundedRectangle.hpp"
|
#include "Widgets/RoundedRectangle.hpp"
|
||||||
#include "Widgets/TextInput.hpp"
|
#include "Widgets/TextInput.hpp"
|
||||||
|
#include "Widgets/CheckBox.hpp" // ORCA
|
||||||
|
|
||||||
class TabCtrl;
|
class TabCtrl;
|
||||||
|
|
||||||
|
@ -557,7 +558,7 @@ private:
|
||||||
void update_filament_overrides_page(const DynamicPrintConfig* printers_config);
|
void update_filament_overrides_page(const DynamicPrintConfig* printers_config);
|
||||||
void update_volumetric_flow_preset_hints();
|
void update_volumetric_flow_preset_hints();
|
||||||
|
|
||||||
std::map<std::string, wxCheckBox*> m_overrides_options;
|
std::map<std::string, ::CheckBox*> m_overrides_options;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
//BBS: GUI refactor
|
//BBS: GUI refactor
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue