branch: externals/listen
commit df7252257c50a732014b86474d43c06ceac702c7
Author: Adam Porter <a...@alphapapa.net>
Commit: Adam Porter <a...@alphapapa.net>

    Add: (listen-queue) Indicate current queue in mode line
---
 README.org      | 1 +
 docs/README.org | 1 +
 listen-queue.el | 7 ++++++-
 3 files changed, 8 insertions(+), 1 deletion(-)

diff --git a/README.org b/README.org
index e87a631c3f..b6016b9fc0 100644
--- a/README.org
+++ b/README.org
@@ -227,6 +227,7 @@ The ~listen-mode~ minor mode runs a timer which plays the 
next track in the curr
 
 *Additions*
 - The ~listen-queue-list~ buffer can be bookmarked.
+- Queue buffers showing the currently playing queue indicate so in the mode 
line.
 
 *Fixes*
 - Command ~listen-queue-add-from-mpd~.
diff --git a/docs/README.org b/docs/README.org
index bdd311c11b..127e9d45c6 100644
--- a/docs/README.org
+++ b/docs/README.org
@@ -239,6 +239,7 @@ The ~listen-mode~ minor mode runs a timer which plays the 
next track in the curr
 
 *Additions*
 + The ~listen-queue-list~ buffer can be bookmarked.
++ Queue buffers showing the currently playing queue indicate so in the mode 
line.
 
 *Fixes*
 + Command ~listen-queue-add-from-mpd~.
diff --git a/listen-queue.el b/listen-queue.el
index 16f5609d05..af71471755 100644
--- a/listen-queue.el
+++ b/listen-queue.el
@@ -117,7 +117,12 @@ Useful for when `save-excursion' does not preserve point."
 (define-derived-mode listen-queue-mode special-mode "Listen-Queue"
   (toggle-truncate-lines 1)
   (hl-line-mode 1)
-  (setq-local bookmark-make-record-function 
#'listen-queue--bookmark-make-record))
+  (setq-local bookmark-make-record-function 
#'listen-queue--bookmark-make-record
+              mode-name
+              '("Listen-Queue"
+                (:eval (when (and listen-player
+                                  (eq listen-queue (alist-get :queue 
(listen-player-etc listen-player))))
+                         (propertize ":current" 'face 
'font-lock-builtin-face))))))
 
 ;;;###autoload
 (defun listen-queue (queue)

Reply via email to