Update to new raw-window-handle strategy
Signed-off-by: John Nunley <dev@notgull.net> Co-authored-by: TornaxO7 <tornax@proton.me>
This commit is contained in:
parent
bbeacc46d5
commit
e41fac825c
26 changed files with 662 additions and 242 deletions
|
|
@ -16,7 +16,6 @@ use core_foundation::runloop::{
|
|||
};
|
||||
use icrate::Foundation::{MainThreadMarker, NSString};
|
||||
use objc2::ClassType;
|
||||
use raw_window_handle::{RawDisplayHandle, UiKitDisplayHandle};
|
||||
|
||||
use crate::{
|
||||
error::EventLoopError,
|
||||
|
|
@ -52,8 +51,20 @@ impl<T: 'static> EventLoopWindowTarget<T> {
|
|||
#[inline]
|
||||
pub fn listen_device_events(&self, _allowed: DeviceEvents) {}
|
||||
|
||||
pub fn raw_display_handle(&self) -> RawDisplayHandle {
|
||||
RawDisplayHandle::UiKit(UiKitDisplayHandle::empty())
|
||||
#[cfg(feature = "rwh_05")]
|
||||
#[inline]
|
||||
pub fn raw_display_handle_rwh_05(&self) -> rwh_05::RawDisplayHandle {
|
||||
rwh_05::RawDisplayHandle::UiKit(rwh_05::UiKitDisplayHandle::empty())
|
||||
}
|
||||
|
||||
#[cfg(feature = "rwh_06")]
|
||||
#[inline]
|
||||
pub fn raw_display_handle_rwh_06(
|
||||
&self,
|
||||
) -> Result<rwh_06::RawDisplayHandle, rwh_06::HandleError> {
|
||||
Ok(rwh_06::RawDisplayHandle::UiKit(
|
||||
rwh_06::UiKitDisplayHandle::new(),
|
||||
))
|
||||
}
|
||||
|
||||
pub(crate) fn set_control_flow(&self, control_flow: ControlFlow) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue