pub struct AnyToggleableState { /* private fields */ }Expand description
Erased ToggleableStateMixin: one identity and a static vtable.
This is what a field or parameter Dart types as ToggleableStateMixin becomes, such as the
state a RawRadio hands its RadioBuilder. Equality is Dart’s == on
an object reference.
Implementations§
Source§impl AnyToggleableState
impl AnyToggleableState
Sourcepub fn context(self, app: &App) -> AnyElement
pub fn context(self, app: &App) -> AnyElement
See State::context.
Sourcepub fn mounted(self, app: &App) -> bool
pub fn mounted(self, app: &App) -> bool
See State::mounted.
Sourcepub fn position_controller(self, app: &App) -> Handle<AnimationController>
pub fn position_controller(self, app: &App) -> Handle<AnimationController>
Sourcepub fn reaction_controller(self, app: &App) -> Handle<AnimationController>
pub fn reaction_controller(self, app: &App) -> Handle<AnimationController>
Sourcepub fn reaction_hover_fade(
self,
app: &App,
) -> &Retained<Handle<CurvedAnimation>>
pub fn reaction_hover_fade( self, app: &App, ) -> &Retained<Handle<CurvedAnimation>>
Sourcepub fn reaction_focus_fade(
self,
app: &App,
) -> &Retained<Handle<CurvedAnimation>>
pub fn reaction_focus_fade( self, app: &App, ) -> &Retained<Handle<CurvedAnimation>>
Sourcepub fn reaction_animation_duration(self, app: &App) -> Option<Duration>
pub fn reaction_animation_duration(self, app: &App) -> Option<Duration>
Sourcepub fn is_interactive(self, app: &App) -> bool
pub fn is_interactive(self, app: &App) -> bool
Sourcepub fn animate_to_value(self, app: &mut App)
pub fn animate_to_value(self, app: &mut App)
Sourcepub fn down_position(self, app: &App) -> Option<Offset>
pub fn down_position(self, app: &App) -> Option<Offset>
Sourcepub fn states(self, app: &App) -> HashSet<WidgetState>
pub fn states(self, app: &App) -> HashSet<WidgetState>
Sourcepub fn build_toggleable(
self,
app: &mut App,
focus_node: Option<Retained<AnyFocusNode>>,
on_focus_change: Option<Rc<dyn Fn(&mut App, bool)>>,
autofocus: bool,
mouse_cursor: Option<Rc<dyn WidgetStateProperty<Rc<dyn MouseCursor>>>>,
size: Size,
painter: impl CustomPainter,
) -> Rc<dyn Widget>
pub fn build_toggleable( self, app: &mut App, focus_node: Option<Retained<AnyFocusNode>>, on_focus_change: Option<Rc<dyn Fn(&mut App, bool)>>, autofocus: bool, mouse_cursor: Option<Rc<dyn WidgetStateProperty<Rc<dyn MouseCursor>>>>, size: Size, painter: impl CustomPainter, ) -> Rc<dyn Widget>
Trait Implementations§
Source§impl Clone for AnyToggleableState
impl Clone for AnyToggleableState
Source§fn clone(&self) -> AnyToggleableState
fn clone(&self) -> AnyToggleableState
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for AnyToggleableState
Source§impl Debug for AnyToggleableState
impl Debug for AnyToggleableState
impl Eq for AnyToggleableState
Auto Trait Implementations§
impl Forget for AnyToggleableState
impl Freeze for AnyToggleableState
impl Move for AnyToggleableState
impl RefUnwindSafe for AnyToggleableState
impl Send for AnyToggleableState
impl Sync for AnyToggleableState
impl Unpin for AnyToggleableState
impl UnsafeUnpin for AnyToggleableStatewhere
NonZeroU32Inner: UnsafeUnpin,
&'static ToggleableStateVTable: UnsafeUnpin,
impl UnwindSafe for AnyToggleableState
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Convert
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Convert
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
Convert
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.Source§impl<T> DowncastSync for T
impl<T> DowncastSync for T
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.