diff --git a/Cargo.lock b/Cargo.lock index cdbb38f..04d136c 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -89,9 +89,9 @@ dependencies = [ [[package]] name = "appit" -version = "0.1.0" +version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c843008d81c05e90e716349b2fa73017583f40965bf1651a34fa5fa7159eeef7" +checksum = "e3441f2d5169d7cce48f58cc16a802b6bb6e9e3edf80712ac56c681a09b92ae0" dependencies = [ "winit", ] @@ -3165,9 +3165,9 @@ dependencies = [ [[package]] name = "winnow" -version = "0.5.28" +version = "0.5.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c830786f7720c2fd27a1a0e27a709dbd3c4d009b56d098fc742d4f4eab91fe2" +checksum = "9b5c3db89721d50d0e2a673f5043fc4722f76dcc352d7b1ab8b8288bed4ed2c5" dependencies = [ "memchr", ] diff --git a/Cargo.toml b/Cargo.toml index 4122ebe..a059b40 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -38,8 +38,8 @@ unicode-segmentation = "1.10.1" # [patch."https://github.com/khonsulabs/kludgine"] # kludgine = { path = "../kludgine" } -# [patch."https://github.com/khonsulabs/appit"] -# appit = { path = "../appit" } +# [patch.crates-io] +# appit = { version = "0.1.0", path = "../appit" } # [patch."https://github.com/khonsulabs/figures"] # figures = { path = "../figures" } diff --git a/src/utils.rs b/src/utils.rs index cd49959..0036def 100644 --- a/src/utils.rs +++ b/src/utils.rs @@ -6,13 +6,13 @@ use intentional::Assert; use kludgine::app::winit::event::Modifiers; use kludgine::app::winit::keyboard::ModifiersState; -/// This [`Condvar`] is a wrapper that on Mac OS/iOS asserts unwind safety. On +/// This [`Condvar`] is a wrapper that on Mac OS/iOS/Windows asserts unwind safety. On /// all other platforms, this is a transparent wrapper around `Condvar`. See /// for more information. #[derive(Debug, Default)] pub struct UnwindsafeCondvar( - #[cfg(any(target_os = "ios", target_os = "macos"))] std::panic::AssertUnwindSafe, - #[cfg(not(any(target_os = "ios", target_os = "macos")))] Condvar, + #[cfg(any(target_os = "ios", target_os = "macos", target_os = "windows"))] std::panic::AssertUnwindSafe, + #[cfg(not(any(target_os = "ios", target_os = "macos", target_os = "windows")))] Condvar, ); impl Deref for UnwindsafeCondvar { @@ -25,12 +25,12 @@ impl Deref for UnwindsafeCondvar { impl UnwindsafeCondvar { pub const fn new() -> Self { - #[cfg(any(target_os = "ios", target_os = "macos"))] + #[cfg(any(target_os = "ios", target_os = "macos", target_os = "windows"))] { Self(std::panic::AssertUnwindSafe(Condvar::new())) } - #[cfg(not(any(target_os = "ios", target_os = "macos")))] + #[cfg(not(any(target_os = "ios", target_os = "macos", target_os = "windows")))] { Self(Condvar::new()) } diff --git a/src/window.rs b/src/window.rs index ba0c1e5..e669b01 100644 --- a/src/window.rs +++ b/src/window.rs @@ -5,7 +5,6 @@ use std::ffi::OsStr; use std::ops::{Deref, DerefMut, Not}; use std::panic::{AssertUnwindSafe, UnwindSafe}; use std::path::Path; -use std::process::Command; use std::string::ToString; use std::sync::{MutexGuard, OnceLock}; @@ -1340,7 +1339,7 @@ impl Ranged for ThemeMode { } #[cfg(any(target_os = "macos", target_os = "ios", target_os = "windows"))] -fn default_family(query: Family<'_>) -> Option { +fn default_family(_query: Family<'_>) -> Option { // fontdb uses system APIs to determine these defaults. None } @@ -1360,7 +1359,7 @@ fn default_family(query: Family<'_>) -> Option { Family::Name(_) => return None, }; - Command::new("fc-match") + std::process::Command::new("fc-match") .arg("-f") .arg("%{family}") .arg(query)