Package com.google.gwt.dom.client

Examples of com.google.gwt.dom.client.Touch


     *
     * @param event
     */
    private void touchMove(TouchEvent<?> event) {
        if (event.getTouches().length() > 1) {
            Touch t1 = event.getTouches().get(0);
            Touch t2 = event.getTouches().get(1);

            int left, right;
            if (t1.getClientX() > t2.getClientX()) {
                left = t2.getClientX() - getElement().getAbsoluteLeft();
                right = t1.getClientX() - getElement().getAbsoluteLeft();
            } else {
                left = t1.getClientX() - getElement().getAbsoluteLeft();
                right = t2.getClientX() - getElement().getAbsoluteLeft();
            }

            // Boundary checks
            if (left < 0) {
                left = 0;
View Full Code Here

TOP

Related Classes of com.google.gwt.dom.client.Touch

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.