From 867b0448ef8f10d298826ca3e394fb3153448c0d Mon Sep 17 00:00:00 2001
From: Christian Heller <c.heller@plomlompom.de>
Date: Tue, 27 Aug 2024 13:51:08 +0200
Subject: [PATCH] Remove randomness sorting.

---
 browser.py | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/browser.py b/browser.py
index 266a620..67e41cb 100755
--- a/browser.py
+++ b/browser.py
@@ -1,7 +1,6 @@
 #!/usr/bin/env python3
 from json import dump as json_dump, load as json_load
 from os.path import exists as path_exists, join as path_join, abspath
-from random import shuffle
 from operator import attrgetter
 from exiftool import ExifToolHelper  # type: ignore
 import gi  # type: ignore
@@ -16,7 +15,6 @@ from stable.gen_params import (GenParams,  # noqa: E402
 
 IMG_DIR = '.'
 CACHE_PATH = 'cache.json'
-SORT_KEY_RANDOM = 'randomize'
 
 
 class SortLabelItem(GObject.GObject):
@@ -147,10 +145,6 @@ class Window(Gtk.ApplicationWindow):
     def sort(self):
         self.list_store.remove_all()
         for key in self.sort_order:
-            if SORT_KEY_RANDOM == key:
-                shuffle(self.unsorted_files)
-                shuffle(self.unsorted_dirs)
-                continue
             self.unsorted_files.sort(key=attrgetter(key))
             if key in {'name', 'last_mod_time'}:
                 self.unsorted_dirs.sort(key=attrgetter(key))
-- 
2.30.2