Added snapshot taking for Set Printable/Unprintable for full object

This commit is contained in:
YuSanka 2019-08-07 15:39:46 +02:00
parent d25c5e0473
commit 850fbdbe56

View file

@ -3669,7 +3669,13 @@ void ObjectList::toggle_printable_state(wxDataViewItem item)
ModelObject* object = (*m_objects)[obj_idx];
// get object's printable and change it
bool printable = !m_objects_model->IsPrintable(item);
const bool printable = !m_objects_model->IsPrintable(item);
const wxString snapshot_text = wxString::Format("%s %s",
printable ? _(L("Set Printable")) : _(L("Set Unprintable")),
object->name);
take_snapshot(snapshot_text);
// set printable value for all instances in object
for (auto inst : object->instances)
inst->printable = printable;