Examples of TapAndHoldProcessor


Examples of org.mt4j.input.inputProcessors.componentProcessors.tapAndHoldProcessor.TapAndHoldProcessor

    //Create tail component
    tails = new TouchTailComponent(mtApp);
    this.getCanvas().addChild(tails);
   
    //Add tap&hold gesture to clear all tails
    TapAndHoldProcessor tapAndHold = new TapAndHoldProcessor(mtApplication);
    tapAndHold.setMaxFingerUpDist(10);
    tapAndHold.setHoldTime(3000);
    tails.registerInputProcessor(tapAndHold);
    tails.addGestureListener(TapAndHoldProcessor.class, new IGestureEventListener() {
      public boolean processGestureEvent(MTGestureEvent ge) {
        TapAndHoldEvent t = (TapAndHoldEvent)ge;
        if (t.getId() == TapAndHoldEvent.GESTURE_ENDED && t.isHoldComplete()){
View Full Code Here

Examples of org.mt4j.input.inputProcessors.componentProcessors.tapAndHoldProcessor.TapAndHoldProcessor

    final MTTextArea tapAndHoldOnly = new MTTextArea(mtApplication, font);
    tapAndHoldOnly.setFillColor(textAreaColor);
    tapAndHoldOnly.setStrokeColor(textAreaColor);
    tapAndHoldOnly.setText("Tap&Hold me!  ---");
    this.clearAllGestures(tapAndHoldOnly);
    tapAndHoldOnly.registerInputProcessor(new TapAndHoldProcessor(app, 2000));
    tapAndHoldOnly.addGestureListener(TapAndHoldProcessor.class, new TapAndHoldVisualizer(app, getCanvas()));
    tapAndHoldOnly.addGestureListener(TapAndHoldProcessor.class, new IGestureEventListener() {
      public boolean processGestureEvent(MTGestureEvent ge) {
        TapAndHoldEvent th = (TapAndHoldEvent)ge;
        switch (th.getId()) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.