[gnome-shell/wip/workspace: 136/143] overview: Send the clone with the window-drag events
- From: Jasper St. Pierre <jstpierre src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell/wip/workspace: 136/143] overview: Send the clone with the window-drag events
- Date: Thu, 26 Sep 2013 20:21:58 +0000 (UTC)
commit 605eab5f24c017385d9936b7cd5f30d12e2c9989
Author: Jasper St. Pierre <jstpierre mecheye net>
Date: Wed Sep 11 14:20:39 2013 -0400
overview: Send the clone with the window-drag events
This allows clients that care about the actual item we're dragging to
make smarter decisions without adding a drag monitor themselves.
js/ui/overview.js | 12 ++++++------
js/ui/workspace.js | 12 ++++++------
js/ui/workspaceThumbnail.js | 12 ++++++------
3 files changed, 18 insertions(+), 18 deletions(-)
---
diff --git a/js/ui/overview.js b/js/ui/overview.js
index 78dcf53..7fc984d 100644
--- a/js/ui/overview.js
+++ b/js/ui/overview.js
@@ -445,17 +445,17 @@ const Overview = new Lang.Class({
this._inDrag = false;
},
- beginWindowDrag: function(source) {
- this.emit('window-drag-begin');
+ beginWindowDrag: function(clone) {
+ this.emit('window-drag-begin', clone);
this._inDrag = true;
},
- cancelledWindowDrag: function(source) {
- this.emit('window-drag-cancelled');
+ cancelledWindowDrag: function(clone) {
+ this.emit('window-drag-cancelled', clone);
},
- endWindowDrag: function(source) {
- this.emit('window-drag-end');
+ endWindowDrag: function(clone) {
+ this.emit('window-drag-end', clone);
this._inDrag = false;
},
diff --git a/js/ui/workspace.js b/js/ui/workspace.js
index 57d889c..642fa68 100644
--- a/js/ui/workspace.js
+++ b/js/ui/workspace.js
@@ -1486,17 +1486,17 @@ const Workspace = new Lang.Class({
clone.connect('selected',
Lang.bind(this, this._onCloneSelected));
clone.connect('drag-begin',
- Lang.bind(this, function(clone) {
- Main.overview.beginWindowDrag();
+ Lang.bind(this, function() {
+ Main.overview.beginWindowDrag(clone);
overlay.hide();
}));
clone.connect('drag-cancelled',
- Lang.bind(this, function(clone) {
- Main.overview.cancelledWindowDrag();
+ Lang.bind(this, function() {
+ Main.overview.cancelledWindowDrag(clone);
}));
clone.connect('drag-end',
- Lang.bind(this, function(clone) {
- Main.overview.endWindowDrag();
+ Lang.bind(this, function() {
+ Main.overview.endWindowDrag(clone);
overlay.show();
}));
clone.connect('size-changed',
diff --git a/js/ui/workspaceThumbnail.js b/js/ui/workspaceThumbnail.js
index fa53568..11b4681 100644
--- a/js/ui/workspaceThumbnail.js
+++ b/js/ui/workspaceThumbnail.js
@@ -438,16 +438,16 @@ const WorkspaceThumbnail = new Lang.Class({
this.activate(time);
}));
clone.connect('drag-begin',
- Lang.bind(this, function(clone) {
- Main.overview.beginWindowDrag();
+ Lang.bind(this, function() {
+ Main.overview.beginWindowDrag(clone);
}));
clone.connect('drag-cancelled',
- Lang.bind(this, function(clone) {
- Main.overview.cancelledWindowDrag();
+ Lang.bind(this, function() {
+ Main.overview.cancelledWindowDrag(clone);
}));
clone.connect('drag-end',
- Lang.bind(this, function(clone) {
- Main.overview.endWindowDrag();
+ Lang.bind(this, function() {
+ Main.overview.endWindowDrag(clone);
}));
this._contents.add_actor(clone.actor);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]