refactor(cosmic-theme): Get ThemeMode version from cosmic config derive
This commit is contained in:
parent
4f07d05ee8
commit
f794c53277
1 changed files with 3 additions and 4 deletions
|
|
@ -30,13 +30,12 @@ impl ThemeMode {
|
|||
config.get::<bool>("is_dark")
|
||||
}
|
||||
|
||||
/// version of the theme
|
||||
pub fn version() -> u64 {
|
||||
1
|
||||
pub const fn version() -> u64 {
|
||||
Self::VERSION
|
||||
}
|
||||
|
||||
/// Get the config for the theme mode
|
||||
pub fn config() -> Result<Config, cosmic_config::Error> {
|
||||
Config::new(THEME_MODE_ID, Self::version())
|
||||
Config::new(THEME_MODE_ID, Self::VERSION)
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue