eric6/UI/NotificationWidget.py

changeset 7997
2ca23396c25c
parent 7996
ce1d288659ae
child 8143
2c730d5fd177
diff -r ce1d288659ae -r 2ca23396c25c eric6/UI/NotificationWidget.py
--- a/eric6/UI/NotificationWidget.py	Thu Jan 21 19:24:59 2021 +0100
+++ b/eric6/UI/NotificationWidget.py	Fri Jan 22 14:14:15 2021 +0100
@@ -235,8 +235,12 @@
         # delete the notification
         index = self.__layout.indexOf(notification)
         self.__layout.takeAt(index)
-        self.__notifications.remove(notification)
-        notification.deleteLater()
+        try:
+            self.__notifications.remove(notification)
+            notification.deleteLater()
+        except ValueError:
+            # it was already delete by other method; ignore
+            pass
         
         if self.__layout.count():
             self.__adjustSizeAndPosition()

eric ide

mercurial