diff options
author | Boruch Baum <[email protected]> | 2024-02-04 18:49:22 -0500 |
---|---|---|
committer | Thanos Apollo <[email protected]> | 2024-02-10 10:49:57 +0200 |
commit | 87143791c21235b1bd674ef17f8affd77c3fbaa5 (patch) | |
tree | a8fe82672020cd0e6fa8201538a2467cc8524d41 | |
parent | ff29ac9d862daffc6eb1ac3e7cebc4a9fb541b57 (diff) |
feat(defcustom): yeetube-default-sort-{column,ascending}
-rw-r--r-- | yeetube.el | 15 |
1 files changed, 14 insertions, 1 deletions
@@ -83,6 +83,18 @@ Valid options include: (const "Date") (const "Views") (const "Rating")) + +(defcustom yeetube-default-sort-column "Title" + "Which column to sort the search results table." + :type '(radio (const "Title") + (const "Views") + (const "Duration") + (const "Channel")) + :group 'yeetube) + +(defcustom yeetube-default-sort-ascending nil + "Whether to sort the search results in ascending order." + :type 'boolean :group 'yeetube) (defgroup yeetube-faces nil @@ -496,7 +508,8 @@ FIELDS-FACE-PAIRS is a list of fields and faces." :duration 'yeetube-face-duration :channel 'yeetube-face-channel))) (reverse yeetube-content)) - tabulated-list-sort-key nil) + tabulated-list-sort-key (cons yeetube-default-sort-column + yeetube-default-sort-ascending)) (display-line-numbers-mode 0) (tabulated-list-init-header) (tabulated-list-print)) |