From 13a117579201a7873601de2398640225638719e9 Mon Sep 17 00:00:00 2001 From: Maxim Ermilov Date: Wed, 14 Jul 2010 05:32:41 +0400 Subject: [PATCH] fix "undo remove from favorites" In GSettings, a change notification is generated immediately from context of the _set() call. In GConf, The "value_changed" signal is emitted whenever the server notifies your client program that a value has changed in the database (100% NOT from context of the _set() call). https://bugzilla.gnome.org/show_bug.cgi?id=624296 --- js/ui/appFavorites.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/js/ui/appFavorites.js b/js/ui/appFavorites.js index d916b96b8..2a20123da 100644 --- a/js/ui/appFavorites.js +++ b/js/ui/appFavorites.js @@ -100,10 +100,11 @@ AppFavorites.prototype = { }, removeFavorite: function(appId) { + let app = this._favorites[appId]; if (!this._removeFavorite(appId)) return; - Main.overview.infoBar.setMessage(_("%s has been removed from your favorites.").format(this._favorites[appId].get_name()), + Main.overview.infoBar.setMessage(_("%s has been removed from your favorites.").format(app.get_name()), Lang.bind(this, function () { this._addFavorite(appId); }));