diff options
| author | 2023-05-25 23:37:14 +0200 | |
|---|---|---|
| committer | 2023-05-25 23:37:14 +0200 | |
| commit | c61a4cc21ca4d5019cd10df2f316ebbdb24061f1 (patch) | |
| tree | aba611186298650931cd818d56e21feff35f974f /core | |
| parent | 6c6930b91df0d7637ed6c0f3f4e57a03c5e5896f (diff) | |
| parent | 70fd296ccc69ae135bfbe693b8404d5409ae4332 (diff) | |
| download | iced-c61a4cc21ca4d5019cd10df2f316ebbdb24061f1.tar.gz iced-c61a4cc21ca4d5019cd10df2f316ebbdb24061f1.tar.bz2 iced-c61a4cc21ca4d5019cd10df2f316ebbdb24061f1.zip  | |
Merge pull request #1738 from nicoburns/update-winit-0.28
Update to winit 0.28
Diffstat (limited to 'core')
| -rw-r--r-- | core/src/window.rs | 2 | ||||
| -rw-r--r-- | core/src/window/level.rs | 19 | 
2 files changed, 21 insertions, 0 deletions
diff --git a/core/src/window.rs b/core/src/window.rs index 81bd7e3d..a6dbdfb4 100644 --- a/core/src/window.rs +++ b/core/src/window.rs @@ -2,12 +2,14 @@  pub mod icon;  mod event; +mod level;  mod mode;  mod redraw_request;  mod user_attention;  pub use event::Event;  pub use icon::Icon; +pub use level::Level;  pub use mode::Mode;  pub use redraw_request::RedrawRequest;  pub use user_attention::UserAttention; diff --git a/core/src/window/level.rs b/core/src/window/level.rs new file mode 100644 index 00000000..3878ecac --- /dev/null +++ b/core/src/window/level.rs @@ -0,0 +1,19 @@ +/// A window level groups windows with respect to their z-position. +/// +/// The relative ordering between windows in different window levels is fixed. +/// The z-order of a window within the same window level may change dynamically +/// on user interaction. +#[derive(Debug, Clone, Copy, PartialEq, Eq, Default)] +pub enum Level { +    /// The default behavior. +    #[default] +    Normal, + +    /// The window will always be below normal windows. +    /// +    /// This is useful for a widget-based app. +    AlwaysOnBottom, + +    /// The window will always be on top of normal windows. +    AlwaysOnTop, +}  | 
