Run mundy inside Runtime context in iced_winit

This commit is contained in:
Héctor Ramón Jiménez 2025-10-16 02:43:29 +02:00
parent fe009142cf
commit 0b78f2aa5d
No known key found for this signature in database
GPG key ID: 7CC46565708259A7

View file

@ -540,12 +540,15 @@ async fn run_instance<P>(
.boxed(),
);
mundy::Preferences::once_blocking(
mundy::Interest::ColorScheme,
core::time::Duration::from_millis(200),
)
.map(|preferences| to_mode(preferences.color_scheme))
.unwrap_or_default()
runtime
.enter(|| {
mundy::Preferences::once_blocking(
mundy::Interest::ColorScheme,
core::time::Duration::from_millis(200),
)
})
.map(|preferences| to_mode(preferences.color_scheme))
.unwrap_or_default()
};
#[cfg(not(all(feature = "linux-theme-detection", target_os = "linux")))]