mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-09-08 09:46:55 +00:00
Fix crash on startup if mixed filament has invalid component (#15432)
This commit is contained in:
@@ -3988,16 +3988,16 @@ void Sidebar::update_mixed_filament_list()
|
||||
p->m_panel_mixed_warning->Show(false);
|
||||
|
||||
// Show/dismiss 3D canvas notification for broken mixed filaments
|
||||
if (has_mixed && !broken_set.empty()) {
|
||||
auto* notify = wxGetApp().plater()->get_notification_manager();
|
||||
if (notify)
|
||||
auto* notify = plater->get_notification_manager();
|
||||
GLCanvas3D* view3d_canvas = plater->get_view3D_canvas3D();
|
||||
if(view3d_canvas && view3d_canvas->is_initialized() && notify){
|
||||
if (has_mixed && !broken_set.empty()) {
|
||||
notify->push_notification(NotificationType::BBLMixedFilamentBroken,
|
||||
NotificationManager::NotificationLevel::ErrorNotificationLevel,
|
||||
_u8L("Mixed filament has invalid or mismatched components. Please re-edit affected entries."));
|
||||
} else {
|
||||
auto* notify = wxGetApp().plater()->get_notification_manager();
|
||||
if (notify)
|
||||
} else {
|
||||
notify->close_notification_of_type(NotificationType::BBLMixedFilamentBroken);
|
||||
}
|
||||
}
|
||||
|
||||
if (has_mixed) {
|
||||
|
||||
Reference in New Issue
Block a user