diff --git a/src/platform/windows/window.rs b/src/platform/windows/window.rs index 764008f0..2211e763 100644 --- a/src/platform/windows/window.rs +++ b/src/platform/windows/window.rs @@ -357,19 +357,10 @@ impl Drop for Window { } } -/// A simple wrapper that destroys the window when it is destroyed. +/// A simple non-owning wrapper around a window. #[doc(hidden)] pub struct WindowWrapper(HWND, HDC); -impl Drop for WindowWrapper { - #[inline] - fn drop(&mut self) { - unsafe { - winuser::DestroyWindow(self.0); - } - } -} - unsafe fn init(window: WindowAttributes, pl_attribs: PlatformSpecificWindowBuilderAttributes, inserter: events_loop::Inserter) -> Result { let title = OsStr::new(&window.title).encode_wide().chain(Some(0).into_iter())