Struct raui_core::widget::context::WidgetContext[][src]

pub struct WidgetContext<'a, 'b> {
    pub id: &'a WidgetId,
    pub idref: Option<&'a WidgetRef>,
    pub key: &'a str,
    pub props: &'a mut Props,
    pub shared_props: &'a mut Props,
    pub state: State<'a>,
    pub animator: &'a AnimatorStates,
    pub life_cycle: &'a mut WidgetLifeCycle,
    pub named_slots: HashMap<String, WidgetNode>,
    pub listed_slots: Vec<WidgetNode>,
    pub process_context: &'a mut ProcessContext<'b>,
}

Fields

id: &'a WidgetIdidref: Option<&'a WidgetRef>key: &'a strprops: &'a mut Propsshared_props: &'a mut Propsstate: State<'a>animator: &'a AnimatorStateslife_cycle: &'a mut WidgetLifeCyclenamed_slots: HashMap<String, WidgetNode>listed_slots: Vec<WidgetNode>process_context: &'a mut ProcessContext<'b>

Implementations

impl<'a, 'b> WidgetContext<'a, 'b>[src]

pub fn take_named_slots(&mut self) -> HashMap<String, WidgetNode>[src]

pub fn take_named_slot(&mut self, name: &str) -> WidgetNode[src]

pub fn take_listed_slots(&mut self) -> Vec<WidgetNode>[src]

pub fn use_hook<F>(&mut self, f: F) -> &mut Self where
    F: FnMut(&mut Self), 
[src]

Trait Implementations

impl<'a, 'b> Debug for WidgetContext<'a, 'b>[src]

fn fmt(&self, f: &mut Formatter<'_>) -> Result[src]

Formats the value using the given formatter. Read more

Auto Trait Implementations

impl<'a, 'b> !RefUnwindSafe for WidgetContext<'a, 'b>

impl<'a, 'b> !Send for WidgetContext<'a, 'b>

impl<'a, 'b> !Sync for WidgetContext<'a, 'b>

impl<'a, 'b> Unpin for WidgetContext<'a, 'b> where
    'b: 'a, 

impl<'a, 'b> !UnwindSafe for WidgetContext<'a, 'b>

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

pub fn type_id(&self) -> TypeId[src]

Gets the TypeId of self. Read more

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

pub fn borrow(&self) -> &T[src]

Immutably borrows from an owned value. Read more

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

pub fn borrow_mut(&mut self) -> &mut T[src]

Mutably borrows from an owned value. Read more

impl<T> From<T> for T[src]

pub fn from(t: T) -> T[src]

Performs the conversion.

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

pub fn into(self) -> U[src]

Performs the conversion.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]

Performs the conversion.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>[src]

Performs the conversion.