feat(config): add icon theme property to CosmicTk config

This commit is contained in:
Michael Aaron Murphy 2024-03-18 15:49:01 +01:00 committed by Jeremy Soller
parent 3694304ee5
commit 4154428a63
5 changed files with 24 additions and 5 deletions

View file

@ -563,6 +563,13 @@ impl<T: Application> Cosmic<T> {
}
Message::ToolkitConfig(config) => {
// Change the icon theme if not defined by the application.
if !self.app.core().icon_theme_override
&& crate::icon_theme::default() != config.icon_theme
{
crate::icon_theme::set_default(config.icon_theme.clone());
}
self.app.core_mut().toolkit_config = config;
}