[AppSwitcher] Do not show the glow for icons in alt+tab dialog.

Unlike icons in the application well, do not show the glow used to
indicate running apps.  It is somewhat redundant here.  These are all
running apps and it is fairly clear from the window list if there are
multiple instances available, according to mccann.

https://bugzilla.gnome.org/show_bug.cgi?id=590563
This commit is contained in:
Steve Frécinaux 2009-09-29 14:13:28 +02:00
parent 373fa3c325
commit fee385ba35
3 changed files with 17 additions and 12 deletions

View File

@ -102,7 +102,7 @@ AltTabPopup.prototype = {
// Contruct the AppIcons, sort by time, add to the popup // Contruct the AppIcons, sort by time, add to the popup
let icons = []; let icons = [];
for (let i = 0; i < apps.length; i++) for (let i = 0; i < apps.length; i++)
icons.push(new AppIcon.AppIcon(apps[i], AppIcon.MenuType.BELOW)); icons.push(new AppIcon.AppIcon(apps[i], AppIcon.MenuType.BELOW, false));
icons.sort(Lang.bind(this, this._sortAppIcon)); icons.sort(Lang.bind(this, this._sortAppIcon));
for (let i = 0; i < icons.length; i++) for (let i = 0; i < icons.length; i++)
this._addIcon(icons[i]); this._addIcon(icons[i]);

View File

@ -462,7 +462,7 @@ BaseWellItem.prototype = {
__proto__: AppIcon.AppIcon.prototype, __proto__: AppIcon.AppIcon.prototype,
_init: function(appInfo, isFavorite, hasMenu) { _init: function(appInfo, isFavorite, hasMenu) {
AppIcon.AppIcon.prototype._init.call(this, appInfo, hasMenu ? AppIcon.MenuType.ON_RIGHT : AppIcon.MenuType.NONE); AppIcon.AppIcon.prototype._init.call(this, appInfo, hasMenu ? AppIcon.MenuType.ON_RIGHT : AppIcon.MenuType.NONE, true);
this.isFavorite = isFavorite; this.isFavorite = isFavorite;

View File

@ -54,7 +54,7 @@ function AppIcon(appInfo, menuType) {
} }
AppIcon.prototype = { AppIcon.prototype = {
_init : function(appInfo, menuType) { _init : function(appInfo, menuType, showGlow) {
this.appInfo = appInfo; this.appInfo = appInfo;
this._menuType = menuType; this._menuType = menuType;
@ -104,6 +104,7 @@ AppIcon.prototype = {
ellipsize: Pango.EllipsizeMode.END, ellipsize: Pango.EllipsizeMode.END,
text: appInfo.get_name() }); text: appInfo.get_name() });
nameBox.add_actor(this._name); nameBox.add_actor(this._name);
if (showGlow) {
this._glowBox = new Big.Box({ orientation: Big.BoxOrientation.HORIZONTAL }); this._glowBox = new Big.Box({ orientation: Big.BoxOrientation.HORIZONTAL });
let glowPath = GLib.filename_to_uri(global.imagedir + 'app-well-glow.png', ''); let glowPath = GLib.filename_to_uri(global.imagedir + 'app-well-glow.png', '');
for (let i = 0; i < this.windows.length && i < 3; i++) { for (let i = 0; i < this.windows.length && i < 3; i++) {
@ -114,6 +115,10 @@ AppIcon.prototype = {
} }
this._nameBox.add_actor(this._glowBox); this._nameBox.add_actor(this._glowBox);
this._glowBox.lower(this._name); this._glowBox.lower(this._name);
}
else
this._glowBox = null;
this.actor.append(nameBox, Big.BoxPackFlags.NONE); this.actor.append(nameBox, Big.BoxPackFlags.NONE);
}, },