public class PointerEventsSupport extends Object
Modifier and Type | Field and Description |
---|---|
static PointerEventsSupport |
impl |
Constructor and Description |
---|
PointerEventsSupport() |
Modifier and Type | Method and Description |
---|---|
<any> |
getChangedTouches(NativeEvent event)
Converts data in the event to Touch data structure
|
boolean |
isPointerEvent(NativeEvent event)
Determines if the provided event is Pointer originated
|
boolean |
isPointerTouchEvent(NativeEvent event)
Determines if the incoming NativeEvent is a pointer event with type "touch" or "pen"
|
boolean |
isSupported()
Identifies whether pointer events are supported in the current running browser.
|
void |
setPointerCapture(XElement element,
NativeEvent event)
Assigns a pointer (by pointerId) to a specific Element.
|
void |
sinkPointerEvents(XElement element)
Sink pointer events to given Element.
|
public static final PointerEventsSupport impl
public void sinkPointerEvents(XElement element)
Sink pointer events to given Element.
Makes the assumption that the DOMImpl has already initialized the EventSystem.
element
- the element to sink pointer events forpublic boolean isPointerEvent(NativeEvent event)
event
- the event to be checkedpublic void setPointerCapture(XElement element, NativeEvent event)
Assigns a pointer (by pointerId) to a specific Element.
Unlike Touch events, the event.target changes with pointer events
element
- the element to capture pointer events forevent
- the event to be capturedpublic boolean isPointerTouchEvent(NativeEvent event)
event
- the event to be testedpublic boolean isSupported()
public <any> getChangedTouches(NativeEvent event)
event
- the event to extract changed touches fromCopyright © 2018. All rights reserved.