mirror of
https://github.com/rust-windowing/winit.git
synced 2026-09-01 14:20:05 -04:00
macOS: fix building with feature = "rwh_04"
This commit is contained in:
committed by
Kirill Chibisov
parent
1dec9b4b33
commit
4b1aa51094
@@ -43,3 +43,7 @@ changelog entry.
|
|||||||
### Added
|
### Added
|
||||||
|
|
||||||
- On Web, implement `Error` for `platform::web::CustomCursorError`.
|
- On Web, implement `Error` for `platform::web::CustomCursorError`.
|
||||||
|
|
||||||
|
### Fixed
|
||||||
|
|
||||||
|
- On MacOS, fix building with `feature = "rwh_04"`.
|
||||||
|
|||||||
@@ -1613,7 +1613,7 @@ impl WindowDelegate {
|
|||||||
pub fn raw_window_handle_rwh_04(&self) -> rwh_04::RawWindowHandle {
|
pub fn raw_window_handle_rwh_04(&self) -> rwh_04::RawWindowHandle {
|
||||||
let mut window_handle = rwh_04::AppKitHandle::empty();
|
let mut window_handle = rwh_04::AppKitHandle::empty();
|
||||||
window_handle.ns_window = self.window() as *const WinitWindow as *mut _;
|
window_handle.ns_window = self.window() as *const WinitWindow as *mut _;
|
||||||
window_handle.ns_view = Retained::as_ptr(&self.contentView().unwrap()) as *mut _;
|
window_handle.ns_view = Retained::as_ptr(&self.view()) as *mut _;
|
||||||
rwh_04::RawWindowHandle::AppKit(window_handle)
|
rwh_04::RawWindowHandle::AppKit(window_handle)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user