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

@ -510,7 +510,7 @@ where
vec![widget::Tree::new(&self.text_input as &dyn Widget<_, _, _>)]
}
fn on_event(
fn update(
&mut self,
tree: &mut widget::Tree,
event: Event,
@ -539,7 +539,7 @@ where
let mut local_shell = Shell::new(&mut local_messages);
// Provide it to the widget
self.text_input.on_event(
self.text_input.update(
&mut tree.children[0],
event.clone(),
layout,
@ -728,7 +728,7 @@ where
published_message_to_shell = true;
// Unfocus the input
self.text_input.on_event(
self.text_input.update(
&mut tree.children[0],
Event::Mouse(mouse::Event::ButtonPressed(
mouse::Button::Left,