Fixed color of buttons in select wake up sound menu a nd in select theme menu

This commit is contained in:
Admar Schoonen 2023-04-17 22:04:00 +02:00
parent d418cbdffb
commit d5eb136419
1 changed files with 13 additions and 8 deletions

View File

@ -236,6 +236,17 @@ class MyClockWidget(FloatLayout):
is_arm = is_arm()
def apply_theme(self):
if self.theme_selected == "Automatic":
self.theme = Theme("Light")
else:
self.theme = Theme(self.theme_selected)
self.ids["settings_menu_wake_up_sound_label_top"].color = self.theme.color_font
self.settings_menu_wake_up_sound_Ok_button.color = self.theme.color_font
self.ids["settings_menu_theme_label_top"].color = self.theme.color_font
self.settings_menu_theme_Ok_button.color = self.theme.color_font
def add_themes(self):
x = self.ids["settings_menu_theme_boxlayout"]
gl = GridLayout(
@ -292,10 +303,7 @@ class MyClockWidget(FloatLayout):
x.add_widget(b)
self.settings_menu_theme_Ok_button = b
if self.theme_selected == "Automatic":
self.theme = Theme("Light")
else:
self.theme = Theme(self.theme_selected)
self.apply_theme()
def add_wake_up_sounds(self):
alarm_settings = App.get_running_app().alarm_settings
@ -949,10 +957,7 @@ class MyClockWidget(FloatLayout):
self.theme_selected = theme
if theme == "Automatic":
self.theme = Theme("Light")
else:
self.theme = Theme(theme)
self.apply_theme()
def volume_slider_value(self, *args):
alarm_settings = App.get_running_app().alarm_settings