Namespaces

Enumerations

enum class DeviceType : uint32_t
Name Value Comments
kTouch 1u

A device intended for manipulation by direct contact over its surface.

kMouse 2u

A device intended for manipulation by precise movement over a surface.

A characterization of a device that issues pointer event streams.

Defined at line 19 of file fidling/gen/sdk/fidl/fuchsia.ui.pointerinjector/fuchsia.ui.pointerinjector/cpp/fidl/fuchsia.ui.pointerinjector/cpp/common_types.h

enum class DispatchPolicy : uint32_t
Name Value Comments
kExclusiveTarget 1u

A single client latches onto a pointer event stream, where:
- the pointer event stream starts within the viewport rectangle,
- the latch happens on the ADD phase of the pointer event stream,
- the client is the |Target| itself.
Ownership is assigned immediately to the client.

Note: This policy guarantees confidentiality, integrity, and
availability of dispatch to the client, but by itself, does *not*
confer immunity against UI redress attacks.

kTopHitAndAncestorsInTarget 2u

Multiple clients may latch onto a pointer stream, where:
- the pointer stream starts within the viewport rectangle,
- a hit test is performed on the ADD phase of the pointer event stream,
which returns the top-most surface (in paint order) in the |Target|'s
view tree,
- the top-most surface's client latches onto the pointer stream,
- the client's ancestors in the |Target|'s view tree also latch onto the
pointer stream.

With multiple latches, a pointer stream is dispatched in parallel to
each latched client, until ownership is assigned via gesture
disambiguation. The owner client will continue to receive the pointer
stream, and non-owners will receive a final CANCEL event for the stream.

Note: It's possible for no clients to latch, if the hit test fails to
hit any surface in any sub-view of |Target|.
Note: Each client will have its own copy of the viewport, placed
accordingly in its own coordinate system.

kMouseHoverAndLatchInTarget 3u

The top hit client in the |Target|'s view tree receives hover events when
a cursor is positioned over it, unless the mouse is latched to a specific
client.

A mouse initiates a latch via button down, and until the release of that
latch, mouse events are delivered to that latched client; other clients
do not receive hover events in the latch duration.

Note: It's possible for no client to latch, if the hit test fails to
hit any surface in any sub-view of |Target|.
Note: Each client will have its own copy of the viewport, placed
accordingly in its own coordinate system.

A specification of the UI clients that may have injected events dispatched

to them in an |Target|. One is specified in |Config|.

A useful concept is "latching", where one or more clients may start

receiving the pointer event stream, prior to assignment of stream ownership.

After ownership is assigned (e.g., through a gesture disambiguation

protocol), non-owning clients have their latch terminated -- they stop

receiving the pointer event stream.

- A client's latch does not itself confer stream ownership (receiving the

entire pointer event stream); gesture disambiguation or device termination

may prematurely end the stream dispatched to that client.

- It's possible for a client to latch while hidden from the user (i.e.,

manipulate a surface that is invisible to the user), where the occluding

surface is owned by a client outside of |Target|. Conversely, these

occluding clients cannot latch, because latched clients must be in

|Target|'s view tree.

Defined at line 60 of file fidling/gen/sdk/fidl/fuchsia.ui.pointerinjector/fuchsia.ui.pointerinjector/cpp/fidl/fuchsia.ui.pointerinjector/cpp/common_types.h

enum class EventPhase : uint32_t
Name Value Comments
kAdd 1u

The device has started tracking the pointer.

kChange 2u

The device has reported an update to the pointer state.

kRemove 3u

The device has stopped tracking the pointer.

kCancel 4u

The event stream is no longer available.

The possible states of a pointer event stream's state machine.

A typical pointer will move through this state machine:

ADD - CHANGE* - REMOVE

Defined at line 128 of file fidling/gen/sdk/fidl/fuchsia.ui.pointerinjector/fuchsia.ui.pointerinjector/cpp/fidl/fuchsia.ui.pointerinjector/cpp/common_types.h

Records