[gnome-shell] Only show the primary monitor region in the workspace thumbnails
- From: Alexander Larsson <alexl src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell] Only show the primary monitor region in the workspace thumbnails
- Date: Thu, 17 Mar 2011 13:34:08 +0000 (UTC)
commit a1a068a377b1b8f729cd89d5e803c672bd61d715
Author: Alexander Larsson <alexl redhat com>
Date: Mon Feb 28 20:09:23 2011 +0100
Only show the primary monitor region in the workspace thumbnails
Make the thumbnail the size of the primary monitor and only show
the windows from that area.
https://bugzilla.gnome.org/show_bug.cgi?id=609258
js/ui/workspaceThumbnail.js | 12 +++++++-----
1 files changed, 7 insertions(+), 5 deletions(-)
---
diff --git a/js/ui/workspaceThumbnail.js b/js/ui/workspaceThumbnail.js
index 9aeab98..2446abb 100644
--- a/js/ui/workspaceThumbnail.js
+++ b/js/ui/workspaceThumbnail.js
@@ -169,7 +169,8 @@ WorkspaceThumbnail.prototype = {
this._background = new Clutter.Clone({ source: global.background_actor });
this._contents.add_actor(this._background);
- this.setPorthole(0, 0, global.screen_width, global.screen_height);
+ let monitor = global.get_primary_monitor();
+ this.setPorthole(monitor.x, monitor.y, monitor.width, monitor.height);
let windows = global.get_window_actors().filter(this._isMyWindow, this);
@@ -442,11 +443,12 @@ ThumbnailsBox.prototype = {
// The "porthole" is the portion of the screen that we show in the workspaces
let panelHeight = Main.panel.actor.height;
+ let monitor = global.get_primary_monitor();
this._porthole = {
- x: 0,
- y: panelHeight,
- width: global.screen_width,
- height: global.screen_height - panelHeight
+ x: monitor.x,
+ y: monitor.y + panelHeight,
+ width: monitor.width,
+ height: monitor.height - panelHeight
};
this.addThumbnails(0, global.screen.n_workspaces);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]