summaryrefslogtreecommitdiffstats
path: root/client
diff options
context:
space:
mode:
authorJohannes Dahlström <johannesd@vaadin.com>2013-02-05 13:38:33 +0000
committerVaadin Code Review <review@vaadin.com>2013-02-05 13:38:33 +0000
commit02900eb97b13a499445a480cae6ce40e3ffc723e (patch)
tree2df70589d0a8788390a47f886a8d7e5152680109 /client
parenta5deb4e342f618e69a5f3a6cd5d3e2913a7cfae0 (diff)
parent093ec0101374a4135540d3e6b0ba4bf1b433ccf1 (diff)
downloadvaadin-framework-02900eb97b13a499445a480cae6ce40e3ffc723e.tar.gz
vaadin-framework-02900eb97b13a499445a480cae6ce40e3ffc723e.zip
Merge "Merge of (#10507) to Vaadin 7." into 7.0
Diffstat (limited to 'client')
-rw-r--r--client/src/com/vaadin/client/ui/AbstractClickEventHandler.java7
1 files changed, 3 insertions, 4 deletions
diff --git a/client/src/com/vaadin/client/ui/AbstractClickEventHandler.java b/client/src/com/vaadin/client/ui/AbstractClickEventHandler.java
index 823618bd8f..bd2654df75 100644
--- a/client/src/com/vaadin/client/ui/AbstractClickEventHandler.java
+++ b/client/src/com/vaadin/client/ui/AbstractClickEventHandler.java
@@ -15,7 +15,6 @@
*/
package com.vaadin.client.ui;
-import com.google.gwt.core.client.JavaScriptObject;
import com.google.gwt.dom.client.NativeEvent;
import com.google.gwt.event.dom.client.ContextMenuEvent;
import com.google.gwt.event.dom.client.ContextMenuHandler;
@@ -49,7 +48,7 @@ public abstract class AbstractClickEventHandler implements MouseDownHandler,
/**
* The element where the last mouse down event was registered.
*/
- private JavaScriptObject lastMouseDownTarget;
+ private Element lastMouseDownTarget;
/**
* Set to true by {@link #mouseUpPreviewHandler} if it gets a mouseup at the
@@ -75,7 +74,7 @@ public abstract class AbstractClickEventHandler implements MouseDownHandler,
Element elementUnderMouse = Util.getElementUnderMouse(event
.getNativeEvent());
if (lastMouseDownTarget != null
- && elementUnderMouse.cast() == lastMouseDownTarget) {
+ && elementUnderMouse == lastMouseDownTarget) {
mouseUpPreviewMatched = true;
} else {
System.out.println("Ignoring mouseup from "
@@ -172,7 +171,7 @@ public abstract class AbstractClickEventHandler implements MouseDownHandler,
* When getting a mousedown event, we must detect where the
* corresponding mouseup event if it's on a different part of the page.
*/
- lastMouseDownTarget = event.getNativeEvent().getEventTarget();
+ lastMouseDownTarget = Util.getElementUnderMouse(event.getNativeEvent());
mouseUpPreviewMatched = false;
mouseUpEventPreviewRegistration = Event
.addNativePreviewHandler(mouseUpPreviewHandler);