Move Windows backend to winit-win32
This commit is contained in:
parent
b1f8d778a1
commit
3b986f5583
26 changed files with 299 additions and 280 deletions
|
|
@ -348,6 +348,30 @@ impl winit_android::EventLoopBuilderExtAndroid for EventLoopBuilder {
|
|||
}
|
||||
}
|
||||
|
||||
#[cfg(windows_platform)]
|
||||
impl winit_win32::EventLoopBuilderExtWindows for EventLoopBuilder {
|
||||
#[inline]
|
||||
fn with_any_thread(&mut self, any_thread: bool) -> &mut Self {
|
||||
self.platform_specific.any_thread = any_thread;
|
||||
self
|
||||
}
|
||||
|
||||
#[inline]
|
||||
fn with_dpi_aware(&mut self, dpi_aware: bool) -> &mut Self {
|
||||
self.platform_specific.dpi_aware = dpi_aware;
|
||||
self
|
||||
}
|
||||
|
||||
#[inline]
|
||||
fn with_msg_hook<F>(&mut self, callback: F) -> &mut Self
|
||||
where
|
||||
F: FnMut(*const core::ffi::c_void) -> bool + 'static,
|
||||
{
|
||||
self.platform_specific.msg_hook = Some(Box::new(callback));
|
||||
self
|
||||
}
|
||||
}
|
||||
|
||||
/// ```compile_error
|
||||
/// use winit::event_loop::run_on_demand::EventLoopExtRunOnDemand;
|
||||
/// use winit::event_loop::EventLoop;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue