api: convert Window to dyn Window
This should allow us to make future split of backends much easier. The `Box<dyn Window>` is a _temporary_ solution, which will be removed with the future updates when we decide on how the Window should be stored.
This commit is contained in:
parent
e716adcc0a
commit
241b7a80bb
41 changed files with 2625 additions and 2448 deletions
|
|
@ -29,6 +29,7 @@ use super::main_thread::MainThreadMarker;
|
|||
use super::r#async::{Dispatcher, Notified, Notifier};
|
||||
use super::web_sys::{Engine, EventListenerHandle};
|
||||
use crate::dpi::{PhysicalPosition, PhysicalSize};
|
||||
use crate::monitor::MonitorHandle as RootMonitorHandle;
|
||||
use crate::platform::web::{
|
||||
MonitorPermissionError, Orientation, OrientationData, OrientationLock, OrientationLockError,
|
||||
};
|
||||
|
|
@ -188,6 +189,12 @@ impl PartialOrd for MonitorHandle {
|
|||
}
|
||||
}
|
||||
|
||||
impl From<MonitorHandle> for RootMonitorHandle {
|
||||
fn from(inner: MonitorHandle) -> Self {
|
||||
RootMonitorHandle { inner }
|
||||
}
|
||||
}
|
||||
|
||||
#[derive(Debug)]
|
||||
pub enum OrientationLockFuture {
|
||||
Future(Notified<Result<(), OrientationLockError>>),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue