Remove custom supports/seams after mesh repair

The repair can remove some of the triangles, so the custom data would make no sense.
This will hopefully fix #5458

Also, show a notification with a hyperlink to undo just before the repair.
This commit is contained in:
Lukas Matena 2020-12-14 14:23:05 +01:00
parent 5553762d9c
commit 1249fdb71d
4 changed files with 61 additions and 20 deletions

View file

@ -1011,7 +1011,13 @@ void NotificationManager::push_notification(const std::string& text, int timesta
{
push_notification_data({ NotificationType::CustomNotification, NotificationLevel::RegularNotification, 10, text }, timestamp);
}
void NotificationManager::push_notification(const std::string& text, NotificationManager::NotificationLevel level, int timestamp)
void NotificationManager::push_notification(NotificationType type,
NotificationLevel level,
const std::string& text,
const std::string& hypertext,
std::function<bool(wxEvtHandler*)> callback,
int timestamp)
{
int duration = 0;
switch (level) {
@ -1022,7 +1028,7 @@ void NotificationManager::push_notification(const std::string& text, Notificatio
assert(false);
return;
}
push_notification_data({ NotificationType::CustomNotification, level, duration, text }, timestamp);
push_notification_data({ type, level, duration, text, hypertext, callback }, timestamp);
}
void NotificationManager::push_slicing_error_notification(const std::string& text)
{