Sequenceablepublic abstract class StylusEvent extends ManipulationEvent
The reported event contains information such as button state change and stylus action (press, slide, or lift). Currently, one event supports only one stylus action.
ManipulationEventSystemCapability.MultimodalInput#MULTIMODAL_INPUTSequenceable.Producer<T>| 限定符和类型 | 字段 | 说明 |
|---|---|---|
static int |
BUTTON_PRESS |
Indicates that the stylus presses on a button.
|
static int |
BUTTON_RELEASE |
Indicates that the stylus lifts up a button.
|
static int |
FIRST_BUTTON |
Indicates button state change in the stylus event.
|
static int |
NONE |
Indicates that the stylus does not perform any operation on the screen.
|
static int |
NONE_BUTTON |
Indicates no button state change in the stylus event.
|
static int |
STYLUS_DOWN |
Indicates that the stylus presses on the screen.
|
static int |
STYLUS_MOVE |
Indicates that the stylus slides on the screen.
|
static int |
STYLUS_UP |
Indicates that the stylus lifts up from the screen.
|
PHASE_CANCEL, PHASE_COMPLETED, PHASE_MOVE, PHASE_NONE, PHASE_STARTBUILTIN_KEY, DEFAULT_TYPE, highLevelEvent, KEYBOARD, MOUSE, ROTATION, SPEECH, STYLUS, TOUCH_PANEL, UNSUPPORTED_DEVICE, uuid| 构造器 | 说明 |
|---|---|
StylusEvent() |
| 限定符和类型 | 方法 | 说明 |
|---|---|---|
abstract int |
getAction() |
Obtains the stylus action.
|
abstract int |
getButtons() |
Obtains the button state change of the stylus.
|
getForce, getPhase, getPointerCount, getPointerId, getPointerPosition, getPointerScreenPosition, getRadius, getStartTime, setScreenOffsetgetDeviceId, getInputDeviceId, getOccurredTime, getSourceDevice, getUuid, isSameEvent, marshalling, unmarshallingclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waithasFileDescriptorpublic static final int BUTTON_PRESS
public static final int BUTTON_RELEASE
public static final int FIRST_BUTTON
public static final int NONE
public static final int NONE_BUTTON
public static final int STYLUS_DOWN
public static final int STYLUS_MOVE
public static final int STYLUS_UP
public abstract int getAction()
BUTTON_PRESS,
BUTTON_RELEASE, STYLUS_DOWN, STYLUS_MOVE, or STYLUS_UP.public abstract int getButtons()
FIRST_BUTTON or NONE_BUTTON.