messageTray: Fix idle tracking condition

The user is active if they have less than IDLETIME, not if
they have more than it.

This fixes an issue where notifications may never go away.

https://bugzilla.gnome.org/show_bug.cgi?id=695659
This commit is contained in:
Jasper St. Pierre 2013-03-11 17:29:41 -04:00
parent 16547fb3c2
commit 78dacfa865

View File

@ -2442,7 +2442,7 @@ const MessageTray = new Lang.Class({
_showNotification: function() {
this._notification = this._notificationQueue.shift();
this._userActiveWhileNotificationShown = this.idleMonitor.get_idletime() > IDLE_TIME;
this._userActiveWhileNotificationShown = this.idleMonitor.get_idletime() <= IDLE_TIME;
if (!this._userActiveWhileNotificationShown) {
// If the user isn't active, set up a watch to let us know
// when the user becomes active.