mirror of
https://github.com/FULU-Foundation/OrcaSlicer-bambulab.git
synced 2026-11-10 03:22:25 +00:00
Fixed two cases of crashes on application close
Both related to ObjectList - it was attempting to call plater after it was destroyed Approved by @YuSanka
This commit is contained in:
1 parent
bcdc8829e4
commit
74799ade14
1 file changed
+6
-2
@@ -77,7 +77,9 @@ static int extruders_count()
|
|||||||
|
|
||||||
static void take_snapshot(const wxString& snapshot_name)
|
static void take_snapshot(const wxString& snapshot_name)
|
||||||
{
|
{
|
||||||
wxGetApp().plater()->take_snapshot(snapshot_name);
|
Plater* plater = wxGetApp().plater();
|
||||||
|
if (plater)
|
||||||
|
plater->take_snapshot(snapshot_name);
|
||||||
}
|
}
|
||||||
|
|
||||||
ObjectList::ObjectList(wxWindow* parent) :
|
ObjectList::ObjectList(wxWindow* parent) :
|
||||||
@@ -3931,7 +3933,9 @@ void ObjectList::OnEditingDone(wxDataViewEvent &event)
|
|||||||
m_last_selected_column = -1;
|
m_last_selected_column = -1;
|
||||||
#endif //__WXMSW__
|
#endif //__WXMSW__
|
||||||
|
|
||||||
wxGetApp().plater()->set_current_canvas_as_dirty();
|
Plater* plater = wxGetApp().plater();
|
||||||
|
if (plater)
|
||||||
|
plater->set_current_canvas_as_dirty();
|
||||||
}
|
}
|
||||||
|
|
||||||
void ObjectList::show_multi_selection_menu()
|
void ObjectList::show_multi_selection_menu()
|
||||||
|
|||||||
Reference in new issue
Block a user