Struct accesskit_unix::Adapter
source · pub struct Adapter { /* private fields */ }
Implementations§
source§impl Adapter
impl Adapter
sourcepub fn new(
source: impl 'static + FnOnce() -> TreeUpdate + Send,
action_handler: Box<dyn ActionHandler + Send>
) -> Self
pub fn new( source: impl 'static + FnOnce() -> TreeUpdate + Send, action_handler: Box<dyn ActionHandler + Send> ) -> Self
Create a new Unix adapter.
pub fn set_root_window_bounds(&self, outer: Rect, inner: Rect)
sourcepub fn update_if_active(&self, update_factory: impl FnOnce() -> TreeUpdate)
pub fn update_if_active(&self, update_factory: impl FnOnce() -> TreeUpdate)
If and only if the tree has been initialized, call the provided function and apply the resulting update.
sourcepub fn update_window_focus_state(&self, is_focused: bool)
pub fn update_window_focus_state(&self, is_focused: bool)
Update the tree state based on whether the window is focused.
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for Adapter
impl Send for Adapter
impl Sync for Adapter
impl Unpin for Adapter
impl !UnwindSafe for Adapter
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more