[gnome-shell] [altTab] Position on the currently focused monitor
- From: Adel Gadllah <agadllah src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [gnome-shell] [altTab] Position on the currently focused monitor
- Date: Mon, 8 Feb 2010 15:12:48 +0000 (UTC)
commit a74cef9d2f74fb6361a1019b2271d5486e2144e8
Author: Adel Gadllah <adel gadllah gmail com>
Date: Sun Feb 7 19:28:35 2010 +0100
[altTab] Position on the currently focused monitor
Show the popup on the currently focused monitor rather than on the primary.
https://bugzilla.gnome.org/show_bug.cgi?id=609257
js/ui/altTab.js | 10 +++++-----
1 files changed, 5 insertions(+), 5 deletions(-)
---
diff --git a/js/ui/altTab.js b/js/ui/altTab.js
index 2a54694..f7a8269 100644
--- a/js/ui/altTab.js
+++ b/js/ui/altTab.js
@@ -84,9 +84,9 @@ AltTabPopup.prototype = {
this._appSwitcher.connect('item-activated', Lang.bind(this, this._appActivated));
this._appSwitcher.connect('item-entered', Lang.bind(this, this._appEntered));
- let primary = global.get_primary_monitor();
- this._appSwitcher.actor.x = primary.x + Math.floor((primary.width - this._appSwitcher.actor.width) / 2);
- this._appSwitcher.actor.y = primary.y + Math.floor((primary.height - this._appSwitcher.actor.height) / 2);
+ let focus = global.get_focus_monitor();
+ this._appSwitcher.actor.x = focus.x + Math.floor((focus.width - this._appSwitcher.actor.width) / 2);
+ this._appSwitcher.actor.y = focus.y + Math.floor((focus.height - this._appSwitcher.actor.height) / 2);
this._appIcons = this._appSwitcher.icons;
@@ -395,8 +395,8 @@ AltTabPopup.prototype = {
thumbnailCenter = stageX + icon.width / 2;
} else {
// Center the thumbnails on the monitor
- let primary = global.get_primary_monitor();
- thumbnailCenter = primary.x + primary.width / 2;
+ let focus = global.get_focus_monitor();
+ thumbnailCenter = focus.x + focus.width / 2;
}
this._thumbnails.actor.x = Math.floor(thumbnailCenter - this._thumbnails.actor.width / 2);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]