From 0fc8c3772155fff60afddcbfdda83a20925780ff Mon Sep 17 00:00:00 2001 From: growfrow <167077685+growfrow@users.noreply.github.com> Date: Sat, 27 Apr 2024 21:29:11 +0800 Subject: [PATCH] chore: fix some typos in comments (#3635) Signed-off-by: growfrow --- src/platform_impl/linux/wayland/window/mod.rs | 2 +- src/platform_impl/linux/x11/event_processor.rs | 2 +- src/platform_impl/linux/x11/util/geometry.rs | 2 +- src/platform_impl/macos/event_loop.rs | 2 +- src/utils.rs | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/platform_impl/linux/wayland/window/mod.rs b/src/platform_impl/linux/wayland/window/mod.rs index 103454ce05..08e4504a83 100644 --- a/src/platform_impl/linux/wayland/window/mod.rs +++ b/src/platform_impl/linux/wayland/window/mod.rs @@ -72,7 +72,7 @@ pub struct Window { /// Source to wake-up the event-loop for window requests. event_loop_awakener: calloop::ping::Ping, - /// The event sink to deliver sythetic events. + /// The event sink to deliver synthetic events. window_events_sink: Arc>, } diff --git a/src/platform_impl/linux/x11/event_processor.rs b/src/platform_impl/linux/x11/event_processor.rs index 19cbba7f30..4eb99cac5b 100644 --- a/src/platform_impl/linux/x11/event_processor.rs +++ b/src/platform_impl/linux/x11/event_processor.rs @@ -1778,7 +1778,7 @@ impl EventProcessor { None => return, }; - // Send the keys using the sythetic state to not alter the main state. + // Send the keys using the synthetic state to not alter the main state. let mut xkb_state = match XkbState::new_x11(xcb, keymap) { Some(xkb_state) => xkb_state, None => return, diff --git a/src/platform_impl/linux/x11/util/geometry.rs b/src/platform_impl/linux/x11/util/geometry.rs index e28b92e4af..63ec564730 100644 --- a/src/platform_impl/linux/x11/util/geometry.rs +++ b/src/platform_impl/linux/x11/util/geometry.rs @@ -180,7 +180,7 @@ impl XConnection { // Position relative to root window. // With rare exceptions, this is the position of a nested window. Cases where the window - // isn't nested are outlined in the comments throghout this function, but in addition to + // isn't nested are outlined in the comments throughout this function, but in addition to // that, fullscreen windows often aren't nested. let (inner_y_rel_root, child) = { let coords = self diff --git a/src/platform_impl/macos/event_loop.rs b/src/platform_impl/macos/event_loop.rs index 6b4f8369c0..d3c5b362ea 100644 --- a/src/platform_impl/macos/event_loop.rs +++ b/src/platform_impl/macos/event_loop.rs @@ -53,7 +53,7 @@ impl PanicInfo { result } - /// Overwrites the curret state if the current state is not panicking + /// Overwrites the current state if the current state is not panicking pub fn set_panic(&self, p: Box) { if !self.is_panicking() { self.inner.set(Some(p)); diff --git a/src/utils.rs b/src/utils.rs index 16f5a4c549..d9631edbb1 100644 --- a/src/utils.rs +++ b/src/utils.rs @@ -1,5 +1,5 @@ // A poly-fill for `lazy_cell` -// Replace with std::sync::LazyLock when https://github.com/rust-lang/rust/issues/109736 is stablized. +// Replace with std::sync::LazyLock when https://github.com/rust-lang/rust/issues/109736 is stabilized. // This isn't used on every platform, which can come up as dead code warnings. #![allow(dead_code)]