Make Widget::on_event return an event::Status

This commit is contained in:
Héctor Ramón Jiménez 2020-11-12 00:09:52 +01:00
parent 1db11ba69a
commit 3f968b8c87
20 changed files with 136 additions and 70 deletions

View file

@ -73,9 +73,10 @@ pub use text::Text;
#[doc(no_inline)]
pub use text_input::TextInput;
use crate::{
layout, overlay, Clipboard, Event, Hasher, Layout, Length, Point, Rectangle,
};
use crate::event::{self, Event};
use crate::layout;
use crate::overlay;
use crate::{Clipboard, Hasher, Layout, Length, Point, Rectangle};
/// A component that displays information and allows interaction.
///
@ -182,7 +183,8 @@ where
_messages: &mut Vec<Message>,
_renderer: &Renderer,
_clipboard: Option<&dyn Clipboard>,
) {
) -> event::Status {
event::Status::Ignored
}
/// Returns the overlay of the [`Element`], if there is any.