Introduce opaque widget helper

This commit is contained in:
Héctor Ramón Jiménez 2024-04-25 06:05:00 +02:00
parent 9492da11d9
commit 4cd45643d7
No known key found for this signature in database
GPG key ID: 7CC46565708259A7
13 changed files with 182 additions and 12 deletions

View file

@ -3,6 +3,7 @@
#[allow(missing_docs)]
pub enum Interaction {
#[default]
None,
Idle,
Pointer,
Grab,

View file

@ -79,7 +79,7 @@ where
_viewport: &Rectangle,
_renderer: &Renderer,
) -> mouse::Interaction {
mouse::Interaction::Idle
mouse::Interaction::None
}
/// Returns true if the cursor is over the [`Overlay`].

View file

@ -137,7 +137,7 @@ where
_viewport: &Rectangle,
_renderer: &Renderer,
) -> mouse::Interaction {
mouse::Interaction::Idle
mouse::Interaction::None
}
/// Returns the overlay of the [`Widget`], if there is any.