# HG changeset patch # User Goffi # Date 1448453096 -3600 # Node ID 0cf705af755cfc1c254f4feafebdda43c994bedb # Parent 8e9a6a9c727e2029440f28b28da071ec20a78ce1 NotificationBar: fixed removePopUp diff -r 8e9a6a9c727e -r 0cf705af755c urwid_satext/sat_widgets.py --- a/urwid_satext/sat_widgets.py Tue Nov 17 12:29:14 2015 +0100 +++ b/urwid_satext/sat_widgets.py Wed Nov 25 13:04:56 2015 +0100 @@ -809,8 +809,13 @@ def removePopUp(self, pop_up_widget): """Remove a popup from the waiting queue""" - self.notifs.remove(pop_up_widget) - self._modQueue() + for idx, (wid_type, widget) in enumerate(self.notifs): + if widget == pop_up_widget: + del self.notifs[idx] + self._modQueue() + return + + raise ValueError(u"trying to remove an unknown pop_up_widget") def addMessage(self, message): "Add a message to the notificatio bar"