GNOME Bugzilla – Bug 704844
dismissing a notification from an action button doesn't correctly hide the close button
Last modified: 2014-03-14 15:13:47 UTC
When I click the Dismiss action button in an Abrt notification the notification slides down but the close button seems to stick around for a bit.
Created attachment 270573 [details] screenshot of the persistent X
This still happens with gnome-shell 3.11.90. Every time the power manager issues a notification that my wireless mouse is running out of battery power, the notification pops up, I close it, and the X button stays on top of all windows. It only goes away when restarting gnome-shell with the "r" command. See screenshot above for better illustration.
Hm, I can't manage to reproduce this. Do you close it with the X button, by clicking on the notification, or with one of the action buttons?
The close button (X on upper right corner) is completely inert to anything, clicking it does nothing. Clicking the notification closes the toaster thing, but the X button stays.
only happens for 'battery critically low' here. haven't been able yet to make out what the difference between this notification and other criticals is.
I just saw a close button left behind by an xchat notification (notably, I've tweaked my notification configuration to set forceExpand to true for xchat). In my debug spew, I notice that the notificationState remained SHOWING all the way through until the notification was destroyed. I think that may be related to the problem here, since updateState only looks for HIDDEN / SHOWN states and basically ignores the intermediate ones.
I also note that once we are in this state (notification destroyed, but notificationState stuck in SHOWING), new notifications will not show up anymore.
pretty sure this is related to force expand. I now regularly get leftover close buttons from xchat notifications, since I set force expand for it.
Created attachment 271659 [details] [review] messageTray: Set the state to SHOWN when the notification is updated If the notification is updated while SHOWING, we'll overwrite the tween updating it to the new 'y' position, but forget to update the state to SHOWN at the end of our transition. Make sure to always set the state to SHOWN at the end.
This fixes the problem here.
Review of attachment 271659 [details] [review]: OK (its ugly though).
Attachment 271659 [details] pushed as c675c93 - messageTray: Set the state to SHOWN when the notification is updated