pub struct Effect<M> { /* private fields */ }Expand description
What Widget::update asks for: async work, plus requests to the host.
Implementations§
Source§impl<M> Effect<M>
impl<M> Effect<M>
pub fn none() -> Self
pub fn task(task: Task<M>) -> Self
Sourcepub fn open_popover(self) -> Self
pub fn open_popover(self) -> Self
Opens this widget’s popover, under its item. Ignored if the widget has no popover.
pub fn close_popover(self) -> Self
Sourcepub fn nudge(self, nudge: Nudge) -> Self
pub fn nudge(self, nudge: Nudge) -> Self
Nudges this widget’s island. Ignored while the island is held or has a popover.
Sourcepub fn nudge_lasting(self, nudge: Nudge, lasting: Duration) -> Self
pub fn nudge_lasting(self, nudge: Nudge, lasting: Duration) -> Self
Nudges this widget’s island in step with something else on screen that takes lasting,
like the compositor’s own workspace animation: the host plays the same motion, slowed down
or sped up to settle over about that long.
Trait Implementations§
Auto Trait Implementations§
impl<M> !RefUnwindSafe for Effect<M>
impl<M> !Sync for Effect<M>
impl<M> !UnwindSafe for Effect<M>
impl<M> Freeze for Effect<M>
impl<M> Send for Effect<M>
impl<M> Unpin for Effect<M>
impl<M> UnsafeUnpin for Effect<M>where
Task<M>: UnsafeUnpin,
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