def on_list_view_button_clicked(self, button): if not isinstance(self.icon_window, TreeWindow): self.remove(self.icon_window) self.icon_window = TreeWindow(self, self.app) self.pack_end(self.icon_window, True, True, 0) self.icon_window.show_all() self.reload()
def on_list_view_button_clicked(self, list_view_button): if not isinstance(self.icon_window, TreeWindow): self.remove(self.icon_window) self.icon_window = TreeWindow(self, self.app) self.pack_end(self.icon_window, True, True, 0) self.icon_window.show_all() self.app.profile['view-mode'][self.name] = const.TREE_VIEW gutil.dump_profile(self.app.profile) self.reload()
def check_first(self): if self.first_run: self.first_run = False if self.app.profile['view-mode'][self.name] == const.ICON_VIEW: self.icon_window = IconWindow(self, self.app) else: self.icon_window = TreeWindow(self, self.app) self.pack_end(self.icon_window, True, True, 0) self.icon_window.show_all() self.load(is_user=True)