mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-11 00:37:51 -06:00
Fixed extra "Add_Selection" snapshot on call context menu from scene
+ Added take_snapshot for toggle_instance_printable_state
This commit is contained in:
parent
52702769d4
commit
0a9c5a9433
3 changed files with 13 additions and 3 deletions
|
@ -1475,7 +1475,14 @@ void Selection::toggle_instance_printable_state()
|
|||
if ((0 <= instance_idx) && (instance_idx < (int)model_object->instances.size()))
|
||||
{
|
||||
ModelInstance* instance = model_object->instances[instance_idx];
|
||||
instance->printable = !instance->printable;
|
||||
const bool printable = !instance->printable;
|
||||
|
||||
wxString snapshot_text = model_object->instances.size() == 1 ? wxString::Format("%s %s",
|
||||
printable ? _(L("Set Printable")) : _(L("Set Unprintable")), model_object->name) :
|
||||
printable ? _(L("Set Printable Instance")) : _(L("Set Unprintable Instance"));
|
||||
wxGetApp().plater()->take_snapshot(snapshot_text);
|
||||
|
||||
instance->printable = printable;
|
||||
|
||||
for (GLVolume* volume : *m_volumes)
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue