Skip to content

Commit bcffaf2

Browse files
committed
Fix a bug with showing self.switcher_bar on bigger screens
1 parent 83ecc6d commit bcffaf2

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

src/gui/window.py

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -544,7 +544,6 @@ def save_config(self):
544544
self.archive_name = f"{self.folder}/{self.filename_text}"
545545
self.status_title = _("<big><b>Saving configuration …</b></big>\nThe configuration of your desktop environment will be saved in:\n <i>{}/{}.sd.tar.gz</i>\n").split('</b>')[0].split('<b>')[-1]
546546
self.status_desc = self._set_status_desc_save()
547-
print(self._set_status_desc_save())
548547
self.done_title = _("Configuration has been saved!")
549548
self.done_desc = _("<big><b>{}</b></big>\nYou can now view the archive with the configuration of your desktop environment, or return to the previous page.\n").format(_("Configuration has been saved!"))
550549

@@ -636,8 +635,9 @@ def _set_default_widgets_state(self):
636635
self.toolbarview.set_content(self.headapp)
637636
self.headerbar.set_title_widget(self.switcher_title)
638637
self.set_title("Save Desktop")
639-
self.switcher_bar.set_reveal(True)
640638
self.apply_handler = self.break_point.connect("apply", self.__on_break_point_apply)
639+
if self.get_default_size()[0] < 400:
640+
self.switcher_bar.set_reveal(True)
641641

642642
# config has been saved action
643643
def done(self):
@@ -699,7 +699,11 @@ def _add_specific_button(self):
699699

700700
def _back_to_main(self, w):
701701
self._set_default_widgets_state()
702-
for widget in [self.status_page, self.open_folder_button, self.logout_button, self.back_button]:
702+
if self.archive_mode == "--create":
703+
widgets = [self.status_page, self.open_folder_button, self.back_button]
704+
else:
705+
widgets = [self.status_page, self.logout_button, self.back_button]
706+
for widget in widgets:
703707
self.status_box.remove(widget)
704708

705709
# show message dialog in the error case

0 commit comments

Comments
 (0)