From: Denis Anisimov Date: Sat, 5 Apr 2014 10:23:50 +0000 (+0300) Subject: Start drag only when mouse left button is pressed (#9814). X-Git-Tag: 7.2.0.beta1~17 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=eb5ffa3a414c2def6d669067f647c06c70c3c5eb;p=vaadin-framework.git Start drag only when mouse left button is pressed (#9814). Change-Id: Ibe9734185af0e6ba4399b20f2f1bb55a3207abd5 --- diff --git a/client/src/com/vaadin/client/ui/VDragAndDropWrapper.java b/client/src/com/vaadin/client/ui/VDragAndDropWrapper.java index bf17929f40..237d2b55c2 100644 --- a/client/src/com/vaadin/client/ui/VDragAndDropWrapper.java +++ b/client/src/com/vaadin/client/ui/VDragAndDropWrapper.java @@ -82,6 +82,7 @@ public class VDragAndDropWrapper extends VCustomComponent implements @Override public void onMouseDown(MouseDownEvent event) { if (getConnector().isEnabled() + && event.getNativeEvent().getButton() == Event.BUTTON_LEFT && startDrag(event.getNativeEvent())) { event.preventDefault(); // prevent text selection }