pub enum CoordinatorListenerRequest {
OnDisplaysChanged {
added: Vec<Info>,
removed: Vec<DisplayId>,
control_handle: CoordinatorListenerControlHandle,
},
OnVsync {
display_id: DisplayId,
timestamp: i64,
applied_config_stamp: ConfigStamp,
cookie: VsyncAckCookie,
control_handle: CoordinatorListenerControlHandle,
},
OnClientOwnershipChange {
has_ownership: bool,
control_handle: CoordinatorListenerControlHandle,
},
_UnknownMethod {
ordinal: u64,
control_handle: CoordinatorListenerControlHandle,
method_type: MethodType,
},
}
Expand description
Provides updates from a Coordinator
to one of its clients.
This protocol solely consists of one-way methods.
Variants§
OnDisplaysChanged
Called when the set of connected displays changes.
Also used to communicate the set of connected displays to a newly connected client.
After this method is called, all applied and draft configurations may no
longer be valid. The client must validate and apply a new configuration,
by calling [Coordinator.CheckConfig
] and [Coordinator.ApplyConfig
].
added
and removed
must not be both empty.
OnVsync
Called on every display Vertical Synchronization (Vsync).
Clients must acknowledge VSync events via the method
[Coordinator.AcknowledgeVsync
]. The coordinator may throttle a client
that accumulates a certain number of unacknowledged VSync cookies.
Throttled clients do not receive VSync events.
After a the client catches up on acknowledging cookies, the coordinator will unthrottle it (resume sending VSync events). Throttled clients may miss some VSync events, as the coordinator is allowed to drop VSync event information for throttled clients.
When dropping VSync event information for throttled clients, the coordinator should prioritize retaining the information for newer events. In other words, the oldest unreported events should be dropped first.
OnClientOwnershipChange
Called when the corresponding Coordinator
client gains or loses
ownership of the displays.
A Coordinator
client’s active config is displayed iff it holds the
ownership of the displays.
A new Coordinator
client should assume they do not have ownership
of the displays until this method informs them otherwise.
_UnknownMethod
An interaction was received which does not match any known method.
Fields
This variant is marked as non-exhaustive
control_handle: CoordinatorListenerControlHandle
method_type: MethodType
Implementations§
Source§impl CoordinatorListenerRequest
impl CoordinatorListenerRequest
pub fn into_on_displays_changed( self, ) -> Option<(Vec<Info>, Vec<DisplayId>, CoordinatorListenerControlHandle)>
pub fn into_on_vsync( self, ) -> Option<(DisplayId, i64, ConfigStamp, VsyncAckCookie, CoordinatorListenerControlHandle)>
pub fn into_on_client_ownership_change( self, ) -> Option<(bool, CoordinatorListenerControlHandle)>
Sourcepub fn method_name(&self) -> &'static str
pub fn method_name(&self) -> &'static str
Name of the method defined in FIDL