Class GestureChain
- java.lang.Object
-
- com.sencha.gxt.core.client.gestures.GestureChain
-
- All Implemented Interfaces:
GestureRecognizer
public class GestureChain extends Object implements GestureRecognizer
Groups gestures together, in order of which should have first crack an an incoming event. Does not supportstart(java.util.List)orgetTouches().
-
-
Constructor Summary
Constructors Constructor Description GestureChain(GestureRecognizer... gestures)GestureChain(List<GestureRecognizer> gestures)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcancel()Ends recognition of the gesture, and fires any cancel events that apply.List<TouchData>getTouches()Gets all actively recognized touches that are being recognized by this gesture.booleanhandle(com.google.gwt.dom.client.NativeEvent event)Takes a browser event, and checks to see if it should decipher a gesture from it.voidsetDelegate(com.google.gwt.event.shared.HasHandlers eventDelegate)Sets delegate to receive Gesture eventsvoidstart(List<TouchData> touches)Artificially starts a gesture
-
-
-
Constructor Detail
-
GestureChain
public GestureChain(GestureRecognizer... gestures)
-
GestureChain
public GestureChain(List<GestureRecognizer> gestures)
-
-
Method Detail
-
cancel
public void cancel()
Description copied from interface:GestureRecognizerEnds recognition of the gesture, and fires any cancel events that apply. Any touch events being recognized by this object will now be ignored.- Specified by:
cancelin interfaceGestureRecognizer
-
getTouches
public List<TouchData> getTouches()
Description copied from interface:GestureRecognizerGets all actively recognized touches that are being recognized by this gesture.- Specified by:
getTouchesin interfaceGestureRecognizer- Returns:
- the touches
-
handle
public boolean handle(com.google.gwt.dom.client.NativeEvent event)
Description copied from interface:GestureRecognizerTakes a browser event, and checks to see if it should decipher a gesture from it.
Callers of this are expected to do their own vetting to decide if the given event should be handled by this gesture - for example, if a cell accepts a tap on one part of it and a longpress on another, the cell should determine where the touch events occur and send to the right recognizer accordingly.
- Specified by:
handlein interfaceGestureRecognizer- Parameters:
event- the browser event to read for a gesture.- Returns:
- true if the gesture is not handling the event and can allow it to be propagated, false to indicate that it has been handled and should not be given to other handlers. Should always return true for any start event.
-
start
public void start(List<TouchData> touches)
Description copied from interface:GestureRecognizerArtificially starts a gesture- Specified by:
startin interfaceGestureRecognizer- Parameters:
touches- the touches to be started
-
setDelegate
public void setDelegate(com.google.gwt.event.shared.HasHandlers eventDelegate)
Description copied from interface:GestureRecognizerSets delegate to receive Gesture events- Specified by:
setDelegatein interfaceGestureRecognizer- Parameters:
eventDelegate- the event handler delegate
-
-