pub trait UiRuntimeDriver {
type Error;
// Required methods
fn idle_poll_ms(&self) -> u32;
fn active_poll_ms(&self) -> u32;
fn needs_active_poll(&self) -> bool;
fn delay_ms(&mut self, delay_ms: u32);
fn now_ms(&self) -> u32;
fn poll_touch(
&mut self,
now_ms: u32,
) -> Result<Option<TouchEvent>, Self::Error>;
}Expand description
OEM-owned timing and touch adapter used by run_ui_system.
Required Associated Types§
Required Methods§
Sourcefn idle_poll_ms(&self) -> u32
fn idle_poll_ms(&self) -> u32
Poll interval used while the UI is idle.
Sourcefn active_poll_ms(&self) -> u32
fn active_poll_ms(&self) -> u32
Poll interval used while the UI is actively animating or tracking touch.
Sourcefn needs_active_poll(&self) -> bool
fn needs_active_poll(&self) -> bool
Returns true when the runtime should use Self::active_poll_ms.
Sourcefn poll_touch(&mut self, now_ms: u32) -> Result<Option<TouchEvent>, Self::Error>
fn poll_touch(&mut self, now_ms: u32) -> Result<Option<TouchEvent>, Self::Error>
Polls the current touch source.