mirror of
https://github.com/rust-windowing/winit.git
synced 2026-08-30 05:10:03 -04:00
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:
committed by
Kirill Chibisov
parent
c59d6bc809
commit
8455f3415e
@@ -15,7 +15,7 @@ use raw_window_handle::{OrbitalDisplayHandle, RawDisplayHandle};
|
||||
use crate::{
|
||||
error::EventLoopError,
|
||||
event::{self, Ime, Modifiers, StartCause},
|
||||
event_loop::{self, ControlFlow},
|
||||
event_loop::{self, ControlFlow, DeviceEvents},
|
||||
keyboard::{
|
||||
Key, KeyCode, KeyLocation, ModifiersKeys, ModifiersState, NativeKey, NativeKeyCode,
|
||||
},
|
||||
@@ -765,6 +765,9 @@ impl<T: 'static> EventLoopWindowTarget<T> {
|
||||
v
|
||||
}
|
||||
|
||||
#[inline]
|
||||
pub fn listen_device_events(&self, _allowed: DeviceEvents) {}
|
||||
|
||||
pub fn raw_display_handle(&self) -> RawDisplayHandle {
|
||||
RawDisplayHandle::Orbital(OrbitalDisplayHandle::empty())
|
||||
}
|
||||
|
||||
@@ -426,6 +426,8 @@ impl Window {
|
||||
|
||||
#[inline]
|
||||
pub fn set_theme(&self, _theme: Option<window::Theme>) {}
|
||||
|
||||
pub fn set_content_protected(&self, _protected: bool) {}
|
||||
}
|
||||
|
||||
impl Drop for Window {
|
||||
|
||||
Reference in New Issue
Block a user