summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--client/src/com/vaadin/client/ui/dd/VDragAndDropManager.java19
1 files changed, 6 insertions, 13 deletions
diff --git a/client/src/com/vaadin/client/ui/dd/VDragAndDropManager.java b/client/src/com/vaadin/client/ui/dd/VDragAndDropManager.java
index 7de40f9496..b911c28a07 100644
--- a/client/src/com/vaadin/client/ui/dd/VDragAndDropManager.java
+++ b/client/src/com/vaadin/client/ui/dd/VDragAndDropManager.java
@@ -422,20 +422,13 @@ public class VDragAndDropManager {
}
case Event.ONMOUSEMOVE:
case Event.ONTOUCHMOVE:
- // only start the drag if the mouse / touch has moved a minimum distance
- int startX = Util.getTouchOrMouseClientX(currentDrag.getCurrentGwtEvent());
- int startY = Util.getTouchOrMouseClientY(currentDrag.getCurrentGwtEvent());
- int nowX = Util.getTouchOrMouseClientX(event.getNativeEvent());
- int nowY = Util.getTouchOrMouseClientY(event.getNativeEvent());
- if (Math.abs(startX - nowX) > 3 || Math.abs(startY - nowY) > 3) {
- if (deferredStartRegistration != null) {
- deferredStartRegistration.removeHandler();
- deferredStartRegistration = null;
- }
- currentDrag.setCurrentGwtEvent(event
- .getNativeEvent());
- startDrag.execute();
+ if (deferredStartRegistration != null) {
+ deferredStartRegistration.removeHandler();
+ deferredStartRegistration = null;
}
+ currentDrag.setCurrentGwtEvent(event
+ .getNativeEvent());
+ startDrag.execute();
break;
default:
// on any other events, clean up the