From d90c98130e1dd5afaf3c94cc7b2526cf4895e696 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Florian=20M=C3=BCllner?= Date: Wed, 9 Feb 2011 23:39:28 +0100 Subject: [PATCH] app-display: Always select "All" filter on switch When switching to the app view, it is unlikely that a user is going to select an application from the same filter list as the last time the view was used, so reset the view to the "All" filter on switch. https://bugzilla.gnome.org/show_bug.cgi?id=641987 --- js/ui/appDisplay.js | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/js/ui/appDisplay.js b/js/ui/appDisplay.js index 97dcd0f91..ad3da75c0 100644 --- a/js/ui/appDisplay.js +++ b/js/ui/appDisplay.js @@ -112,6 +112,13 @@ ViewByCategories.prototype = { this.actor.add(this._view.actor, { expand: true, x_fill: true, y_fill: true }); this.actor.add(this._filters, { expand: false, y_fill: false, y_align: St.Align.START }); + // Always select the "All" filter when switching to the app view + this.actor.connect('notify::mapped', Lang.bind(this, + function() { + if (this.actor.mapped) + this._selectCategory(-1); + })); + this._sections = []; },