Example usage for com.vaadin.client Util getTouchOrMouseClientY

List of usage examples for com.vaadin.client Util getTouchOrMouseClientY

Introduction

In this page you can find the example usage for com.vaadin.client Util getTouchOrMouseClientY.

Prototype

@Deprecated
public static int getTouchOrMouseClientY(NativeEvent currentGwtEvent) 

Source Link

Usage

From source file:fi.jasoft.draganddrop.client.DragAndDropConnector.java

License:Apache License

private static void updateDragImagePosition(NativeEvent event) {
    if (dragElement != null) {
        Style style = dragElement.getStyle();
        int clientY = Util.getTouchOrMouseClientY(event);
        int clientX = Util.getTouchOrMouseClientX(event);
        style.setTop(clientY, Unit.PX);//from w w w  .ja v  a 2s .  com
        style.setLeft(clientX, Unit.PX);
    }
}