[gnome-shell] [Overview] Postpone window repositioning while zooming
- From: Florian Müllner <fmuellner src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell] [Overview] Postpone window repositioning while zooming
- Date: Wed, 24 Mar 2010 18:53:58 +0000 (UTC)
commit 8b3d4857aae27b5c87939b1605b6e0a95fcdb36a
Author: Florian Müllner <fmuellner src gnome org>
Date: Sun Mar 21 19:33:52 2010 +0100
[Overview] Postpone window repositioning while zooming
After closing a window, the remaining previews are repositioned
after a timeout; when it is called while the user zooms a preview,
the window positions get all messed up, so postpone the positioning
in this case until the zoom ends.
https://bugzilla.gnome.org/show_bug.cgi?id=613536
js/ui/workspace.js | 12 ++++++++++++
1 files changed, 12 insertions(+), 0 deletions(-)
---
diff --git a/js/ui/workspace.js b/js/ui/workspace.js
index 9894935..a1a3d2b 100644
--- a/js/ui/workspace.js
+++ b/js/ui/workspace.js
@@ -135,6 +135,7 @@ WindowClone.prototype = {
this._draggable.connect('drag-end', Lang.bind(this, this._onDragEnd));
this.inDrag = false;
+ this._windowIsZooming = false;
this._zooming = false;
this._selected = false;
},
@@ -1209,6 +1210,9 @@ Workspace.prototype = {
},
_delayedWindowRepositioning: function() {
+ if (this._windowIsZooming)
+ return true;
+
let [child, x, y, mask] =
Gdk.Screen.get_default().get_root_window().get_pointer();
let wsWidth = this.actor.width * this.scale;
@@ -1533,6 +1537,14 @@ Workspace.prototype = {
this.emit('window-drag-end', clone.actor);
overlay.show();
}));
+ clone.connect('zoom-start',
+ Lang.bind(this, function() {
+ this._windowIsZooming = true;
+ }));
+ clone.connect('zoom-end',
+ Lang.bind(this, function() {
+ this._windowIsZooming = false;
+ }));
this.actor.add_actor(clone.actor);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]