Slightly reduce number of cfgs (#3071)
* Make Linux platforms less dependent on the root monitor handle * Add various functions to the Wayland platform to reduce cfgs * Don't use a cfg in listen_device_events * Don't use a cfg in set_content_protected * Fix instance of a target_os cfg
This commit is contained in:
parent
67b041e231
commit
a06ea45c0f
19 changed files with 121 additions and 125 deletions
|
|
@ -19,7 +19,9 @@ use sctk::reexports::client::{Connection, Proxy, QueueHandle, WaylandSource};
|
|||
use crate::dpi::{LogicalSize, PhysicalSize};
|
||||
use crate::error::{EventLoopError, OsError as RootOsError};
|
||||
use crate::event::{Event, InnerSizeWriter, StartCause, WindowEvent};
|
||||
use crate::event_loop::{ControlFlow, EventLoopWindowTarget as RootEventLoopWindowTarget};
|
||||
use crate::event_loop::{
|
||||
ControlFlow, DeviceEvents, EventLoopWindowTarget as RootEventLoopWindowTarget,
|
||||
};
|
||||
use crate::platform::pump_events::PumpStatus;
|
||||
use crate::platform_impl::platform::min_timeout;
|
||||
use crate::platform_impl::platform::sticky_exit_callback;
|
||||
|
|
@ -681,6 +683,9 @@ pub struct EventLoopWindowTarget<T> {
|
|||
}
|
||||
|
||||
impl<T> EventLoopWindowTarget<T> {
|
||||
#[inline]
|
||||
pub fn listen_device_events(&self, _allowed: DeviceEvents) {}
|
||||
|
||||
pub fn raw_display_handle(&self) -> RawDisplayHandle {
|
||||
let mut display_handle = WaylandDisplayHandle::empty();
|
||||
display_handle.display = self.connection.display().id().as_ptr() as *mut _;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue