mirror of
https://github.com/DYefremov/DemonEditor.git
synced 2025-12-23 17:09:41 +01:00
changing profile on data download
This commit is contained in:
@@ -140,6 +140,7 @@ class DownloadDialog:
|
||||
if active in self._settings.profiles:
|
||||
self._settings.current_profile = active
|
||||
self._profile_combo_box.set_active_id(active)
|
||||
self._s_type = self._settings.setting_type
|
||||
self.init_ui_settings()
|
||||
|
||||
def on_info_bar_close(self, bar=None, resp=None):
|
||||
|
||||
@@ -895,6 +895,10 @@ class Application(Gtk.Application):
|
||||
yield from self.clear_current_data()
|
||||
|
||||
try:
|
||||
current_profile = self._profile_combo_box.get_active_text()
|
||||
if current_profile != self._settings.current_profile:
|
||||
self.init_profiles(self._settings.current_profile)
|
||||
|
||||
prf = self._s_type
|
||||
black_list = get_blacklist(data_path)
|
||||
bouquets = get_bouquets(data_path, prf)
|
||||
|
||||
@@ -175,12 +175,12 @@ class SettingsDialog:
|
||||
update_entry_data(entry, self._dialog, self._settings)
|
||||
|
||||
def on_settings_type_changed(self, item):
|
||||
profile = SettingsType.ENIGMA_2 if self._enigma_radio_button.get_active() else SettingsType.NEUTRINO_MP
|
||||
self._s_type = profile
|
||||
self._settings.setting_type = profile
|
||||
if profile is not self._s_type:
|
||||
s_type = SettingsType.ENIGMA_2 if self._enigma_radio_button.get_active() else SettingsType.NEUTRINO_MP
|
||||
if s_type is not self._s_type:
|
||||
self._settings.setting_type = s_type
|
||||
self._s_type = s_type
|
||||
self.on_reset()
|
||||
self.init_ui_elements(profile)
|
||||
self.init_ui_elements(s_type)
|
||||
|
||||
def on_reset(self, item=None):
|
||||
self._settings.reset()
|
||||
|
||||
Reference in New Issue
Block a user