ENH: increase the warning level of which blocking cloud slice

Jira: STUDIO-4457

Change-Id: I9a3be983cd5c585ed498829482e6b2202f4d5717
This commit is contained in:
liz.li 2023-09-14 17:33:27 +08:00 committed by Lane.Wei
parent 50051b82d1
commit 1b12dae4c7
3 changed files with 8 additions and 4 deletions

View file

@ -5786,7 +5786,11 @@ void Plater::priv::on_slicing_update(SlicingStatusEvent &evt)
// Now process state.warnings.
for (auto const& warning : state.warnings) {
if (warning.current) {
notification_manager->push_slicing_warning_notification(warning.message, false, model_object, object_id, warning_step, warning.message_id);
NotificationManager::NotificationLevel notif_level = NotificationManager::NotificationLevel::WarningNotificationLevel;
if (evt.status.message_type == PrintStateBase::SlicingNotificationType::SlicingReplaceInitEmptyLayers | PrintStateBase::SlicingNotificationType::SlicingEmptyGcodeLayers) {
notif_level = NotificationManager::NotificationLevel::SeriousWarningNotificationLevel;
}
notification_manager->push_slicing_warning_notification(warning.message, false, model_object, object_id, warning_step, warning.message_id, notif_level);
add_warning(warning, object_id.id);
}
}