This commit is contained in:
Jonathan Warren 2013-11-06 23:41:37 -05:00
parent d34114d14c
commit 74c7c99511
1 changed files with 8 additions and 1 deletions

View File

@ -1218,7 +1218,14 @@ class MyForm(QtGui.QMainWindow):
if withMessagingMenu:
n = Notify.Notification.new(
title, subtitle, 'notification-message-email')
n.show()
try:
n.show()
except:
# n.show() has been known to throw this exception:
# gi._glib.GError: GDBus.Error:org.freedesktop.Notifications.
# MaxNotificationsExceeded: Exceeded maximum number of
# notifications
pass
return
else:
self.tray.showMessage(title, subtitle, 1, 2000)