mirror of
https://github.com/rust-windowing/winit.git
synced 2026-06-26 22:53:15 -04:00
Fix compilation errors
This commit is contained in:
@@ -2,7 +2,9 @@ use crate::dpi::{LogicalPosition, LogicalSize};
|
||||
use crate::error::{ExternalError, NotSupportedError, OsError as RootOE};
|
||||
use crate::icon::Icon;
|
||||
use crate::monitor::MonitorHandle as RootMH;
|
||||
use crate::window::{CursorIcon, WindowAttributes, WindowId as RootWI};
|
||||
use crate::window::{CursorIcon, Fullscreen, WindowAttributes, WindowId as RootWI};
|
||||
|
||||
use raw_window_handle::{RawWindowHandle, web::WebHandle};
|
||||
|
||||
use super::{backend, monitor, EventLoopWindowTarget};
|
||||
|
||||
@@ -203,13 +205,13 @@ impl Window {
|
||||
}
|
||||
|
||||
#[inline]
|
||||
pub fn fullscreen(&self) -> Option<RootMH> {
|
||||
pub fn fullscreen(&self) -> Option<Fullscreen> {
|
||||
// TODO: should there be a maximization / fullscreen API?
|
||||
None
|
||||
}
|
||||
|
||||
#[inline]
|
||||
pub fn set_fullscreen(&self, _monitor: Option<RootMH>) {
|
||||
pub fn set_fullscreen(&self, _monitor: Option<Fullscreen>) {
|
||||
// TODO: should there be a maximization / fullscreen API?
|
||||
}
|
||||
|
||||
@@ -254,6 +256,16 @@ impl Window {
|
||||
pub fn id(&self) -> Id {
|
||||
return self.id;
|
||||
}
|
||||
|
||||
#[inline]
|
||||
pub fn raw_window_handle(&self) -> raw_window_handle::RawWindowHandle {
|
||||
let handle = WebHandle {
|
||||
id: self.id.0,
|
||||
..WebHandle::empty()
|
||||
};
|
||||
|
||||
raw_window_handle::RawWindowHandle::Web(handle)
|
||||
}
|
||||
}
|
||||
|
||||
#[derive(Debug, Copy, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
|
||||
|
||||
Reference in New Issue
Block a user