[gnome-shell] workspace.js: remove some dead code



commit 1d2f0e0e15ed5853d0e59d8f11fcb4d486eb0278
Author: Dan Winship <danw gnome org>
Date:   Thu Apr 8 14:39:45 2010 -0400

    workspace.js: remove some dead code
    
    The original window dnd code needed to track whether or not the
    pointer was in the clone. Some later rewrite made this unnecessary,
    but we were still keeping track anyway.

 js/ui/workspace.js |   27 ---------------------------
 1 files changed, 0 insertions(+), 27 deletions(-)
---
diff --git a/js/ui/workspace.js b/js/ui/workspace.js
index 63a0ba8..63ee3fc 100644
--- a/js/ui/workspace.js
+++ b/js/ui/workspace.js
@@ -121,11 +121,8 @@ WindowClone.prototype = {
                            Lang.bind(this, this._onScroll));
 
         this.actor.connect('destroy', Lang.bind(this, this._onDestroy));
-        this.actor.connect('enter-event',
-                           Lang.bind(this, this._onEnter));
         this.actor.connect('leave-event',
                            Lang.bind(this, this._onLeave));
-        this._havePointer = false;
 
         this._draggable = DND.makeDraggable(this.actor,
                                             { dragActorMaxSize: WINDOW_DND_SIZE,
@@ -179,23 +176,7 @@ WindowClone.prototype = {
         this.disconnectAll();
     },
 
-    _onEnter: function (actor, event) {
-        // If the user drags faster than we can follow, he'll end up
-        // leaving the window temporarily and then re-entering it
-        if (this.inDrag)
-            return;
-
-        this._havePointer = true;
-    },
-
     _onLeave: function (actor, event) {
-        // If the user drags faster than we can follow, he'll end up
-        // leaving the window temporarily and then re-entering it
-        if (this.inDrag)
-            return;
-
-        this._havePointer = false;
-
         if (this._zoomStep)
             this._zoomEnd();
     },
@@ -298,14 +279,6 @@ WindowClone.prototype = {
     _onDragEnd : function (draggable, time, snapback) {
         this.inDrag = false;
 
-        // Most likely, the clone is going to move away from the
-        // pointer now. But that won't cause a leave-event, so
-        // do this by hand. Of course, if the window only snaps
-        // back a short distance, this might be wrong, but it's
-        // better to have the label mysteriously missing than
-        // mysteriously present
-        this._havePointer = false;
-
         // We may not have a parent if DnD completed successfully, in
         // which case our clone will shortly be destroyed and replaced
         // with a new one on the target workspace.



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]