From 9b96af66027bce630c1296372c7b74c701bbeccb Mon Sep 17 00:00:00 2001 From: Vincent Vermeulen Date: Sat, 19 Jun 2021 09:19:00 +0200 Subject: [PATCH] fix recently used documents sorting recently used documents were incorrectly sorted on when a file was first added to recently-used.xbel file, not reflecting when it was opened again later this fix changes it so they are sorted correctly on when they were last used (when last their entry was modified in recently-used.xbel) fixes https://github.com/linuxmint/mint20.2-beta/issues/10 --- usr/lib/linuxmint/mintMenu/plugins/recent.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/usr/lib/linuxmint/mintMenu/plugins/recent.py b/usr/lib/linuxmint/mintMenu/plugins/recent.py index c16524c..39f89d3 100755 --- a/usr/lib/linuxmint/mintMenu/plugins/recent.py +++ b/usr/lib/linuxmint/mintMenu/plugins/recent.py @@ -197,7 +197,7 @@ class pluginclass: def GetRecent(self, *args, **kargs): FileString=[] IconString=[] - RecentInfo=self.RecManagerInstance.get_items() + RecentInfo=sorted(self.RecManagerInstance.get_items(), key=lambda item: item.get_modified(), reverse=True) count=0 MaxEntries=self.numentries if self.numentries == -1: