mirror of
https://github.com/GradienceTeam/Gradience.git
synced 2024-07-01 00:49:56 +00:00
Fixed custom CSS not resetting when loading presets without the custom CSS field
This commit is contained in:
parent
0e5d5d011a
commit
470930db36
|
@ -10,8 +10,6 @@ i18n = import('i18n')
|
||||||
|
|
||||||
gnome = import('gnome')
|
gnome = import('gnome')
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
subdir('data')
|
subdir('data')
|
||||||
subdir('src')
|
subdir('src')
|
||||||
subdir('po')
|
subdir('po')
|
||||||
|
|
|
@ -193,6 +193,9 @@ class AdwcustomizerApplication(Adw.Application):
|
||||||
self.palette = preset["palette"]
|
self.palette = preset["palette"]
|
||||||
if "custom_css" in preset:
|
if "custom_css" in preset:
|
||||||
self.custom_css = preset["custom_css"]
|
self.custom_css = preset["custom_css"]
|
||||||
|
else:
|
||||||
|
for app_type in self.settings_schema["custom_css_app_types"]:
|
||||||
|
self.custom_css[app_type] = ""
|
||||||
for key in self.variables.keys():
|
for key in self.variables.keys():
|
||||||
if key in self.pref_variables:
|
if key in self.pref_variables:
|
||||||
self.pref_variables[key].update_value(self.variables[key])
|
self.pref_variables[key].update_value(self.variables[key])
|
||||||
|
|
Loading…
Reference in a new issue