mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-05-17 02:22:17 +00:00
FIX: the error message dialog is always show when modify params
Jira: STUDIO-4781 Change-Id: I93797861843e89fdc80be38859bd8043b2b51aa6
This commit is contained in:
@@ -1424,6 +1424,23 @@ void Tab::on_value_change(const std::string& opt_key, const boost::any& value)
|
||||
}
|
||||
}
|
||||
|
||||
if (opt_key == "print_sequence" && m_config->opt_enum<PrintSequence>("print_sequence") == PrintSequence::ByObject) {
|
||||
auto printer_structure_opt = wxGetApp().preset_bundle->printers.get_edited_preset().config.option<ConfigOptionEnum<PrinterStructure>>("printer_structure");
|
||||
if (printer_structure_opt && printer_structure_opt->value == PrinterStructure::psI3) {
|
||||
wxString msg_text = _(L("When print by object, machines with I3 structure will not generate timelapse videos."));
|
||||
msg_text += "\n\n" + _(L("Still print by object?"));
|
||||
|
||||
MessageDialog dialog(wxGetApp().plater(), msg_text, "", wxICON_WARNING | wxYES | wxNO);
|
||||
auto answer = dialog.ShowModal();
|
||||
if (answer == wxID_NO) {
|
||||
DynamicPrintConfig new_conf = *m_config;
|
||||
new_conf.set_key_value("print_sequence", new ConfigOptionEnum<PrintSequence>(PrintSequence::ByLayer));
|
||||
m_config_manipulation.apply(m_config, &new_conf);
|
||||
wxGetApp().plater()->update();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// BBS set support style to default when support type changes
|
||||
if (opt_key == "support_type") {
|
||||
DynamicPrintConfig new_conf = *m_config;
|
||||
|
||||
Reference in New Issue
Block a user