diff options
author | Christian Duerr <contact@christianduerr.com> | 2024-02-13 22:08:33 +0100 |
---|---|---|
committer | Christian Duerr <contact@christianduerr.com> | 2024-03-19 02:20:53 +0100 |
commit | 564eb65201b30e85ea1551d6167d67b9f8b11482 (patch) | |
tree | 4e5429647b121f79bf3c7fbef56b79e6ecee7999 | |
parent | 935aee6165f4ae4d3bf40557a8be53cd4cdf719b (diff) | |
download | alacritty-564eb65201b30e85ea1551d6167d67b9f8b11482.tar.gz alacritty-564eb65201b30e85ea1551d6167d67b9f8b11482.zip |
Fix clippy warnings
-rw-r--r-- | alacritty/src/event.rs | 1 | ||||
-rw-r--r-- | alacritty/src/input/mod.rs | 3 |
2 files changed, 4 insertions, 0 deletions
diff --git a/alacritty/src/event.rs b/alacritty/src/event.rs index ff08557b..e1ee20f8 100644 --- a/alacritty/src/event.rs +++ b/alacritty/src/event.rs @@ -917,6 +917,7 @@ impl<'a, N: Notify + 'a, T: EventListener> input::ActionContext<T> for ActionCon self.config } + #[cfg(target_os = "macos")] fn event_loop(&self) -> &EventLoopWindowTarget<Event> { self.event_loop } diff --git a/alacritty/src/input/mod.rs b/alacritty/src/input/mod.rs index 5bc95bdf..9a96b45b 100644 --- a/alacritty/src/input/mod.rs +++ b/alacritty/src/input/mod.rs @@ -19,6 +19,7 @@ use winit::dpi::PhysicalPosition; use winit::event::{ ElementState, Modifiers, MouseButton, MouseScrollDelta, Touch as TouchEvent, TouchPhase, }; +#[cfg(target_os = "macos")] use winit::event_loop::EventLoopWindowTarget; use winit::keyboard::ModifiersState; #[cfg(target_os = "macos")] @@ -103,6 +104,7 @@ pub trait ActionContext<T: EventListener> { fn pop_message(&mut self) {} fn message(&self) -> Option<&Message>; fn config(&self) -> &UiConfig; + #[cfg(target_os = "macos")] fn event_loop(&self) -> &EventLoopWindowTarget<Event>; fn mouse_mode(&self) -> bool; fn clipboard_mut(&mut self) -> &mut Clipboard; @@ -1216,6 +1218,7 @@ mod tests { self.clipboard } + #[cfg(target_os = "macos")] fn event_loop(&self) -> &EventLoopWindowTarget<Event> { unimplemented!(); } |