class GeometryProvider

Defined at line 23 of file ../../src/ui/scenic/lib/view_tree/geometry_provider.h

This class is responsible for registering and maintaining server endpoints for

fuchsia.ui.observation.geometry.ViewTreeWatcher protocol clients. This class also listens for new

snapshots generated every frame, and sends a processed version of them to these registered

clients.

Public Methods

void GeometryProvider ()

Defined at line 25 of file ../../src/ui/scenic/lib/view_tree/geometry_provider.h

void Register (fidl::InterfaceRequest<fuchsia::ui::observation::geometry::ViewTreeWatcher> endpoint, zx_koid_t context_view)

Adds a server side endpoint to |endpoints_| for lifecycle management.

Defined at line 31 of file ../../src/ui/scenic/lib/view_tree/geometry_provider.cc

void RegisterGlobalViewTreeWatcher (fidl::InterfaceRequest<fuchsia::ui::observation::geometry::ViewTreeWatcher> endpoint)

Adds a server side endpoint provided by

fuchsia.ui.observation.test.Registry.RegisterGlobalViewTreeWatcher to |endpoints_|. Endpoints

registered by this method get a global access to the view tree.

Defined at line 36 of file ../../src/ui/scenic/lib/view_tree/geometry_provider.cc

void OnNewViewTreeSnapshot (std::shared_ptr<const view_tree::Snapshot> snapshot)

Inject a new snapshot of the ViewTree. Adds the snapshot to each ProviderEndpoint's

|view_tree_snapshots_| and send a response to the respective clients if the required conditions

are met. See SendResponseMaybe() for more details on the required conditions.

Defined at line 62 of file ../../src/ui/scenic/lib/view_tree/geometry_provider.cc

fuchsia::ui::observation::geometry::ViewTreeSnapshotPtr ExtractObservationSnapshot (std::optional<zx_koid_t> endpoint_context_view, const view_tree::Snapshot & snapshot)

Generates a fuchsia.ui.observation.geometry.ViewTreeSnapshot from the |snapshot| by

extracting information about the |context_view| and its descendant views from

|snapshot|.

Defined at line 81 of file ../../src/ui/scenic/lib/view_tree/geometry_provider.cc