diff options
author | Automerge <automerge@vaadin.com> | 2012-04-13 09:13:52 +0000 |
---|---|---|
committer | Automerge <automerge@vaadin.com> | 2012-04-13 09:13:52 +0000 |
commit | c5095d2981e34cd857c04767a2fcf3a8b5c7f309 (patch) | |
tree | 4dc8e7dc8dbe11b326deb3b03dc774b45b79d29d /src | |
parent | 1cf2e8e1bf024cdc60c3b06f08cf249bca95ebc8 (diff) | |
download | vaadin-framework-c5095d2981e34cd857c04767a2fcf3a8b5c7f309.tar.gz vaadin-framework-c5095d2981e34cd857c04767a2fcf3a8b5c7f309.zip |
[merge from 6.7] #8639 Improved comments
svn changeset:23529/svn branch:6.8
Diffstat (limited to 'src')
-rw-r--r-- | src/com/vaadin/terminal/gwt/client/ui/VScrollTable.java | 31 |
1 files changed, 20 insertions, 11 deletions
diff --git a/src/com/vaadin/terminal/gwt/client/ui/VScrollTable.java b/src/com/vaadin/terminal/gwt/client/ui/VScrollTable.java index a28aebae68..ee33f33758 100644 --- a/src/com/vaadin/terminal/gwt/client/ui/VScrollTable.java +++ b/src/com/vaadin/terminal/gwt/client/ui/VScrollTable.java @@ -5229,23 +5229,32 @@ public class VScrollTable extends FlowPanel implements Table, ScrollHandler, public void run() { TouchScrollDelegate activeScrollDelegate = TouchScrollDelegate .getActiveScrollDelegate(); + /* + * If there's a scroll delegate, check if + * we're actually scrolling and handle it. + * If no delegate, do nothing here and let + * the row handle potential drag'n'drop or + * context menu. + */ if (activeScrollDelegate != null) { - if (!activeScrollDelegate.isMoved()) { + if (activeScrollDelegate.isMoved()) { /* - * scrolling hasn't started. Cancel - * scrolling and let row handle this - * as drag start or context menu. + * Prevent the row from handling + * touch move/end events (the + * delegate handles those) and from + * doing drag'n'drop or opening a + * context menu. */ - activeScrollDelegate - .stopScrolling(); + touchStart = null; } else { /* - * Scrolled or scrolling, clear - * touch start to indicate that row - * shouldn't handle touch move/end - * events. + * Scrolling hasn't started, so + * cancel delegate and let the row + * handle potential drag'n'drop or + * context menu. */ - touchStart = null; + activeScrollDelegate + .stopScrolling(); } } } |