mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-08 15:37:30 -06:00
FIX: coPoint type couldn't display
This causes the printer setting page unable to display becase I added a coPoint type option best_object_pos. Add reading and writing coPoint type configs solves the problem. Jira: STUDIO-4303 Change-Id: I34e40e567236d28ab1a7be265128275191fcc935
This commit is contained in:
parent
7beed5d6dd
commit
c7e78511f5
5 changed files with 72 additions and 11 deletions
|
@ -77,6 +77,7 @@ const t_field& OptionsGroup::build_field(const t_config_option_key& id, const Co
|
|||
case coEnums:
|
||||
m_fields.emplace(id, Choice::Create<Choice>(this->ctrl_parent(), opt, id));
|
||||
break;
|
||||
case coPoint:
|
||||
case coPoints:
|
||||
m_fields.emplace(id, PointCtrl::Create<PointCtrl>(this->ctrl_parent(), opt, id));
|
||||
break;
|
||||
|
@ -1032,6 +1033,9 @@ boost::any ConfigOptionsGroup::get_config_value(const DynamicPrintConfig& config
|
|||
case coEnums:
|
||||
ret = config.opt_int(opt_key, idx);
|
||||
break;
|
||||
case coPoint:
|
||||
ret = config.option<ConfigOptionPoint>(opt_key)->value;
|
||||
break;
|
||||
case coPoints:
|
||||
if (opt_key == "printable_area")
|
||||
ret = config.option<ConfigOptionPoints>(opt_key)->values;
|
||||
|
@ -1144,6 +1148,9 @@ boost::any ConfigOptionsGroup::get_config_value2(const DynamicPrintConfig& confi
|
|||
case coEnums:
|
||||
ret = config.opt_int(opt_key, idx);
|
||||
break;
|
||||
case coPoint:
|
||||
ret = config.option<ConfigOptionPoint>(opt_key)->value;
|
||||
break;
|
||||
case coPoints:
|
||||
if (opt_key == "printable_area")
|
||||
ret = config.option<ConfigOptionPoints>(opt_key)->values;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue