Fix for crash from #7486 - PrusaSlicer crashes when doing this commands
This commit is contained in:
parent
2121a98bea
commit
dc3da0b626
@ -181,6 +181,8 @@ public:
|
||||
// we have to set same max contrtol width to all of them
|
||||
void set_max_win_width(int max_win_width);
|
||||
|
||||
bool is_activated() { return sizer != nullptr; }
|
||||
|
||||
protected:
|
||||
std::map<t_config_option_key, Option> m_options;
|
||||
wxWindow* m_parent {nullptr};
|
||||
|
@ -3933,6 +3933,8 @@ bool Tab::validate_custom_gcodes()
|
||||
bool valid = true;
|
||||
for (auto opt_group : m_active_page->m_optgroups) {
|
||||
assert(opt_group->opt_map().size() == 1);
|
||||
if (!opt_group->is_activated())
|
||||
break;
|
||||
std::string key = opt_group->opt_map().begin()->first;
|
||||
valid &= validate_custom_gcode(opt_group->title, boost::any_cast<std::string>(opt_group->get_value(key)));
|
||||
if (!valid)
|
||||
|
Loading…
Reference in New Issue
Block a user