[gnome-shell] workspace: Fix layout errors caused by window zoom
- From: Florian MÃllner <fmuellner src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell] workspace: Fix layout errors caused by window zoom
- Date: Wed, 6 Jul 2011 20:07:10 +0000 (UTC)
commit 8d1b7962d83e6d8d7d31ad39f43972d61c5b2379
Author: Florian MÃllner <fmuellner gnome org>
Date: Wed Jul 6 17:46:47 2011 +0200
workspace: Fix layout errors caused by window zoom
Commit 64b2b4a7d4 changed the monitor layout handling, resulting
in some layout errors due to a subtle change in memory handling:
when zooming a window in the overview, the available zoom area is
calculated by subtracting the panel height from the primary monitor
area. This area used to be a copy of the monitor rect, but as now
the rect itself is returned, zooming a window on the primary monitor
repeatedly modifies the monitor rect, leading to layout errors in
various parts of the shell.
Fix by using a copy when calculating the available zoom area.
https://bugzilla.gnome.org/show_bug.cgi?id=654105
js/ui/workspace.js | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
---
diff --git a/js/ui/workspace.js b/js/ui/workspace.js
index aaf3994..e6c65b9 100644
--- a/js/ui/workspace.js
+++ b/js/ui/workspace.js
@@ -225,7 +225,11 @@ WindowClone.prototype = {
let [width, height] = this.actor.get_transformed_size();
let monitorIndex = this.metaWindow.get_monitor();
- let availArea = Main.layoutManager.monitors[monitorIndex];
+ let monitor = Main.layoutManager.monitors[monitorIndex];
+ let availArea = new Meta.Rectangle({ x: monitor.x,
+ y: monitor.y,
+ width: monitor.width,
+ height: monitor.height });
if (monitorIndex == Main.layoutManager.primaryIndex) {
availArea.y += Main.panel.actor.height;
availArea.height -= Main.panel.actor.height;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]