From: Christian Heller Date: Sat, 24 Aug 2024 05:58:49 +0000 (+0200) Subject: Preverse previous sort order where new one would not make a difference. X-Git-Url: https://plomlompom.com/repos/te"st.html?a=commitdiff_plain;h=f6a94985b286a410bf6ec81fba48345f02158dfa;p=stable_plom Preverse previous sort order where new one would not make a difference. --- diff --git a/browser.py b/browser.py index f288626..3d43d05 100755 --- a/browser.py +++ b/browser.py @@ -133,8 +133,8 @@ class Window(Gtk.ApplicationWindow): def sort(self, attr_name): self.list_store.remove_all() - for file_item in sorted(self.unsorted, - key=lambda i: getattr(i, attr_name)): + self.unsorted.sort(key=lambda i: getattr(i, attr_name)) + for file_item in self.unsorted: self.list_store.append(file_item) self.update_selected()