[Pkg-javascript-commits] [dojo] 75/149: refs #18298, fix dnd/Moveable issue when dragging outside of a document (e.g. over an iframe). Note, tests for dnd are still in DOH

David Prévot taffit at moszumanska.debian.org
Sat Feb 27 03:13:49 UTC 2016


This is an automated email from the git hooks/post-receive script.

taffit pushed a commit to branch master
in repository dojo.

commit d851143bb2b6e12789228633f78a300464453281
Author: zhao_hongsheng <yisuren at yahoo.com.cn>
Date:   Fri Sep 11 09:58:43 2015 -0700

    refs #18298, fix dnd/Moveable issue when dragging outside of a document (e.g. over an iframe). Note, tests for dnd are still in DOH
---
 dnd/Moveable.js                           | 2 +-
 testsDOH/dnd/test_parent_constraints.html | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/dnd/Moveable.js b/dnd/Moveable.js
index ab252ce..a99238d 100644
--- a/dnd/Moveable.js
+++ b/dnd/Moveable.js
@@ -59,7 +59,7 @@ var Moveable = declare("dojo.dnd.Moveable", [Evented], {
 		if(this.delay){
 			this.events.push(
 				on(this.handle, touch.move, lang.hitch(this, "onMouseMove")),
-				on(this.handle, touch.release, lang.hitch(this, "onMouseUp"))
+				on(this.handle.ownerDocument, touch.release, lang.hitch(this, "onMouseUp"))
 			);
 			this._lastX = e.pageX;
 			this._lastY = e.pageY;
diff --git a/testsDOH/dnd/test_parent_constraints.html b/testsDOH/dnd/test_parent_constraints.html
index df44433..c3f9796 100644
--- a/testsDOH/dnd/test_parent_constraints.html
+++ b/testsDOH/dnd/test_parent_constraints.html
@@ -31,7 +31,7 @@
 	<script type="text/javascript">
 		require(["dojo/dnd/move", "dojo/domReady!"], function(move){
 			var m1, m2, m3, m4;
-			m1 = new move.parentConstrainedMoveable("moveable1", {area: "margin", within: true});
+			m1 = new move.parentConstrainedMoveable("moveable1", {area: "margin", within: true, delay: 20});
 			m2 = new move.parentConstrainedMoveable("moveable2", {area: "border", within: true});
 			m3 = new move.parentConstrainedMoveable("moveable3", {area: "padding", within: true});
 			m4 = new move.parentConstrainedMoveable("moveable4", {area: "content", within: true});

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/dojo.git



More information about the Pkg-javascript-commits mailing list