pub fn try_get_mut<S: Component>(&mut self, entity: Entity) -> Option<&mut S> {
        self.mark_as_dirty(entity);
        if let Some(e) = self.states.get_mut(&entity) {
            if let Some(r) = e.as_any_mut().downcast_mut() {
                return Some(r);
            }
        }

        None
    }
/// Try to get a mutable reference of the state of the given widget.
Try to get a mutable reference of the state of the given widget.
Try to get a mutable reference of the state of the given widget .
pub fn try_get_mut<S: Component>(&mut self, entity: Entity) -> Option<&mut S> {
        self.mark_as_dirty(entity);
        if let Some(e) = self.states.get_mut(&entity) {
            if let Some(r) = e.as_any_mut().downcast_mut() {
                return Some(r);
            }
        }
        None
    }
pub fn try_get_mut < S : Component > ( & mut self , entity : Entity ) -> Option < & mut S > { self . mark_as_dirty ( entity ) ; if let Some ( e ) = self . states . get_mut ( & entity ) { if let Some ( r ) = e . as_any_mut ( ) . downcast_mut ( ) { return Some ( r ) ; } } None }
Try to get a mutable reference of the state of the given widget.
Try to get a mutable reference of the state of the given widget .
&mut self
entity
Entity