mirror of
https://github.com/italicsjenga/winit-sonoma-fix.git
synced 2024-12-23 22:01:31 +11:00
Fix unsafe_op_in_unsafe_fn warning on nightly (#2207)
This commit is contained in:
parent
fb8313aa97
commit
40f48cbeb4
|
@ -808,7 +808,7 @@ impl<'a, T: 'static> InitData<'a, T> {
|
||||||
// The user data will be registered for the window and can be accessed within the window event callback.
|
// The user data will be registered for the window and can be accessed within the window event callback.
|
||||||
pub unsafe fn on_nccreate(&mut self, window: HWND) -> Option<WindowLongPtr> {
|
pub unsafe fn on_nccreate(&mut self, window: HWND) -> Option<WindowLongPtr> {
|
||||||
let runner = self.event_loop.runner_shared.clone();
|
let runner = self.event_loop.runner_shared.clone();
|
||||||
let result = runner.catch_unwind(|| unsafe {
|
let result = runner.catch_unwind(|| {
|
||||||
let mut window = self.create_window(window);
|
let mut window = self.create_window(window);
|
||||||
let window_data = self.create_window_data(&mut window);
|
let window_data = self.create_window_data(&mut window);
|
||||||
(window, window_data)
|
(window, window_data)
|
||||||
|
|
Loading…
Reference in a new issue