Rename Widget::on_event to update

This commit is contained in:
Héctor Ramón Jiménez 2024-10-25 22:06:06 +02:00
parent dcc184b01b
commit f02bfc3f68
No known key found for this signature in database
GPG key ID: 4C07CEC81AFA161F
37 changed files with 67 additions and 67 deletions

View file

@ -311,7 +311,7 @@ where
})
}
fn on_event(
fn update(
&mut self,
tree: &mut Tree,
event: core::Event,
@ -327,7 +327,7 @@ where
let t = tree.state.downcast_mut::<Rc<RefCell<Option<Tree>>>>();
self.with_element_mut(|element| {
element.as_widget_mut().on_event(
element.as_widget_mut().update(
&mut t.borrow_mut().as_mut().unwrap().children[0],
event,
layout,

View file

@ -182,7 +182,7 @@ where
);
}
fn on_event(
fn update(
&mut self,
tree: &mut Tree,
event: Event,
@ -205,7 +205,7 @@ where
layout,
&self.view,
|tree, renderer, layout, element| {
element.as_widget_mut().on_event(
element.as_widget_mut().update(
tree,
event,
layout,