summaryrefslogtreecommitdiffstats
path: root/client
diff options
context:
space:
mode:
authorAnna Koskinen <anna@vaadin.com>2014-11-05 14:09:45 +0200
committerSauli Tähkäpää <sauli@vaadin.com>2014-11-10 13:21:01 +0200
commit63302d572257f2200355c44098e8df9f9c17842e (patch)
treeee0a4bd0f5d767c932913bc9bb22073dcab8d3db /client
parentfead7a7435a360776a93df55e5e9ca9e24fa3fd0 (diff)
downloadvaadin-framework-63302d572257f2200355c44098e8df9f9c17842e.tar.gz
vaadin-framework-63302d572257f2200355c44098e8df9f9c17842e.zip
Column drag'n'drop disables HeaderClickEvents until left-click (#15167)
Change-Id: Ic64c0eb685c3dd9d7fdb10d9e19745ae2cc36be5
Diffstat (limited to 'client')
-rw-r--r--client/src/com/vaadin/client/ui/VScrollTable.java19
1 files changed, 11 insertions, 8 deletions
diff --git a/client/src/com/vaadin/client/ui/VScrollTable.java b/client/src/com/vaadin/client/ui/VScrollTable.java
index 42fef9f0c0..961e32b290 100644
--- a/client/src/com/vaadin/client/ui/VScrollTable.java
+++ b/client/src/com/vaadin/client/ui/VScrollTable.java
@@ -3138,6 +3138,15 @@ public class VScrollTable extends FlowPanel implements HasWidgets,
&& Util.isTouchEventOrLeftMouseButton(event)) {
dragging = false;
DOM.releaseCapture(getElement());
+
+ if (Util.isTouchEvent(event)) {
+ /*
+ * Prevent using in e.g. scrolling and prevent generated
+ * events.
+ */
+ event.preventDefault();
+ event.stopPropagation();
+ }
if (moved) {
hideFloatingCopy();
tHead.removeSlotFocus();
@@ -3149,14 +3158,8 @@ public class VScrollTable extends FlowPanel implements HasWidgets,
reOrderColumn(cid, closestSlot);
}
}
- }
- if (Util.isTouchEvent(event)) {
- /*
- * Prevent using in e.g. scrolling and prevent generated
- * events.
- */
- event.preventDefault();
- event.stopPropagation();
+ moved = false;
+ break;
}
}