Add Window::is_maximized method (#1804)
This commit is contained in:
parent
05125029c6
commit
3f1e09ec0e
11 changed files with 49 additions and 7 deletions
|
|
@ -385,6 +385,12 @@ impl Window {
|
|||
});
|
||||
}
|
||||
|
||||
#[inline]
|
||||
pub fn is_maximized(&self) -> bool {
|
||||
let window_state = self.window_state.lock();
|
||||
window_state.window_flags.contains(WindowFlags::MAXIMIZED)
|
||||
}
|
||||
|
||||
#[inline]
|
||||
pub fn fullscreen(&self) -> Option<Fullscreen> {
|
||||
let window_state = self.window_state.lock();
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@ pub struct WindowState {
|
|||
pub current_theme: Theme,
|
||||
pub preferred_theme: Option<Theme>,
|
||||
pub high_surrogate: Option<u16>,
|
||||
window_flags: WindowFlags,
|
||||
pub window_flags: WindowFlags,
|
||||
}
|
||||
|
||||
#[derive(Clone)]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue