class Injector

Defined at line 70 of file ../../src/ui/scenic/lib/input/injector.h

Implementation of the |fuchsia::ui::pointerinjector::Device| interface. One instance per channel.

Public Methods

void Injector (inspect::Node inspect_node, InjectorSettings settings, Viewport viewport, fidl::InterfaceRequest<fuchsia::ui::pointerinjector::Device> device, fit::function<bool (zx_koid_t, zx_koid_t)> is_descendant_and_connected, fit::function<void ()> on_channel_closed)

Defined at line 135 of file ../../src/ui/scenic/lib/input/injector.cc

zx_status_t IsValidViewport (const fuchsia::ui::pointerinjector::Viewport & viewport)

Check the validity of a Viewport.

Returns ZX_OK if valid, otherwise logs an error message and return appropriate error code.

Defined at line 306 of file ../../src/ui/scenic/lib/input/injector.cc

void Inject (std::vector<fuchsia::ui::pointerinjector::Event> events, InjectCallback callback)

|fuchsia::ui::pointerinjector::Device|

Defined at line 162 of file ../../src/ui/scenic/lib/input/injector.cc

void InjectEvents (std::vector<fuchsia::ui::pointerinjector::Event> events)

TODO: b/465440651 - revisit if we need to add flow control here since no flow control on caller

side.

Defined at line 170 of file ../../src/ui/scenic/lib/input/injector.cc

Protected Methods

void ForwardEvent (fuchsia::ui::pointerinjector::Event & event, StreamId stream_id)

Forwards the event to device-specific handler in InputSystem (and eventually the client).

void CancelStream (uint32_t pointer_id, StreamId stream_id)

Sends an appropriate Cancel event.

const InjectorSettings & settings ()

Defined at line 94 of file ../../src/ui/scenic/lib/input/injector.h

const Viewport & viewport ()

Defined at line 95 of file ../../src/ui/scenic/lib/input/injector.h