pub trait ElementBase: Element {
Show 17 methods
// Provided methods
fn rebuild(self: Handle<Self>, app: &mut App, force: bool) { ... }
fn render_object_attaching_child(
self: Handle<Self>,
app: &App,
) -> Option<AnyElement> { ... }
fn mount(
self: Handle<Self>,
app: &mut App,
parent: Option<AnyElement>,
new_slot: Option<Slot>,
) { ... }
fn update(self: Handle<Self>, app: &mut App, new_widget: WidgetRef) { ... }
fn update_slot(self: Handle<Self>, app: &mut App, new_slot: Option<Slot>) { ... }
fn attach_render_object(
self: Handle<Self>,
app: &mut App,
new_slot: Option<Slot>,
) { ... }
fn detach_render_object(self: Handle<Self>, app: &mut App) { ... }
fn activate(self: Handle<Self>, app: &mut App) { ... }
fn deactivate(self: Handle<Self>, app: &mut App) { ... }
fn unmount(self: Handle<Self>, app: &mut App) { ... }
fn perform_rebuild(self: Handle<Self>, app: &mut App) { ... }
fn did_change_dependencies(self: Handle<Self>, app: &mut App) { ... }
fn attach_notification_tree(self: Handle<Self>, app: &mut App) { ... }
fn build_scope(self: Handle<Self>, app: &App) -> Handle<BuildScope> { ... }
fn mark_needs_build(self: Handle<Self>, app: &mut App) { ... }
fn update_inheritance(self: Handle<Self>, app: &mut App) { ... }
fn render_object(self: Handle<Self>, app: &App) -> Option<AnyRenderObject> { ... }
}Expand description
Dart’s Element bodies, reachable from an override the way super.mount(..) is.
Every Element implements it. An override that must run the inherited body calls it
trait-qualified, ElementBase::mount(self, app, parent, new_slot), at the position Dart
calls super; the Element defaults run the same bodies.
Provided Methods§
Sourcefn rebuild(self: Handle<Self>, app: &mut App, force: bool)
fn rebuild(self: Handle<Self>, app: &mut App, force: bool)
Element.rebuild for an element whose type is known: calls its
perform_rebuild directly rather than through the vtable,
so a first build adds no frame on the way down the tree.
Sourcefn render_object_attaching_child(
self: Handle<Self>,
app: &App,
) -> Option<AnyElement>
fn render_object_attaching_child( self: Handle<Self>, app: &App, ) -> Option<AnyElement>
Element.renderObjectAttachingChild: the single child, if any.
Sourcefn mount(
self: Handle<Self>,
app: &mut App,
parent: Option<AnyElement>,
new_slot: Option<Slot>,
)
fn mount( self: Handle<Self>, app: &mut App, parent: Option<AnyElement>, new_slot: Option<Slot>, )
Element.mount.
Sourcefn attach_render_object(
self: Handle<Self>,
app: &mut App,
new_slot: Option<Slot>,
)
fn attach_render_object( self: Handle<Self>, app: &mut App, new_slot: Option<Slot>, )
Element.attachRenderObject.
Sourcefn detach_render_object(self: Handle<Self>, app: &mut App)
fn detach_render_object(self: Handle<Self>, app: &mut App)
Element.detachRenderObject.
Sourcefn deactivate(self: Handle<Self>, app: &mut App)
fn deactivate(self: Handle<Self>, app: &mut App)
Element.deactivate.
Sourcefn perform_rebuild(self: Handle<Self>, app: &mut App)
fn perform_rebuild(self: Handle<Self>, app: &mut App)
Element.performRebuild: clears the dirty flag.
Sourcefn did_change_dependencies(self: Handle<Self>, app: &mut App)
fn did_change_dependencies(self: Handle<Self>, app: &mut App)
Element.didChangeDependencies.
Sourcefn attach_notification_tree(self: Handle<Self>, app: &mut App)
fn attach_notification_tree(self: Handle<Self>, app: &mut App)
Element.attachNotificationTree: inherit the parent’s notification chain.
Sourcefn build_scope(self: Handle<Self>, app: &App) -> Handle<BuildScope>
fn build_scope(self: Handle<Self>, app: &App) -> Handle<BuildScope>
Element.buildScope: the scope inherited from the parent at mount.
Sourcefn mark_needs_build(self: Handle<Self>, app: &mut App)
fn mark_needs_build(self: Handle<Self>, app: &mut App)
Element.markNeedsBuild.
Sourcefn update_inheritance(self: Handle<Self>, app: &mut App)
fn update_inheritance(self: Handle<Self>, app: &mut App)
Element._updateInheritance.
Sourcefn render_object(self: Handle<Self>, app: &App) -> Option<AnyRenderObject>
fn render_object(self: Handle<Self>, app: &App) -> Option<AnyRenderObject>
Element.renderObject: walk down through the attaching children.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".