summary refs log tree commit diff stats
path: root/lisp/+tab-bar.el
diff options
context:
space:
mode:
authorCase Duckworth2022-02-07 17:09:32 -0600
committerCase Duckworth2022-02-07 17:09:41 -0600
commit801ee6ec245a8a2fffdd81f256eab750634306fc (patch)
treea43984b5a38658c6054a01328485ca219b0e9f42 /lisp/+tab-bar.el
parentRemove emms (diff)
downloademacs-801ee6ec245a8a2fffdd81f256eab750634306fc.tar.gz
emacs-801ee6ec245a8a2fffdd81f256eab750634306fc.zip
Add +bongo-radio
Diffstat (limited to 'lisp/+tab-bar.el')
-rw-r--r--lisp/+tab-bar.el24
1 files changed, 21 insertions, 3 deletions
diff --git a/lisp/+tab-bar.el b/lisp/+tab-bar.el index 6567f67..c5a93dc 100644 --- a/lisp/+tab-bar.el +++ b/lisp/+tab-bar.el
@@ -65,8 +65,14 @@
65 65
66(defun +tab-bar-bongo () 66(defun +tab-bar-bongo ()
67 "Display Bongo now playing information." 67 "Display Bongo now playing information."
68 (when (and bongo-mode-line-indicator-mode 68 (when-let ((modep bongo-mode-line-indicator-mode)
69 (bongo-playing-p)) 69 (buf (cl-some (lambda (b)
70 (with-current-buffer b
71 (when-let* ((modep (derived-mode-p 'bongo-playlist-mode))
72 (bongo-playlist-buffer b)
73 (playingp (bongo-playing-p)))
74 b)))
75 (buffer-list))))
70 `((bongo-now-playing menu-item 76 `((bongo-now-playing menu-item
71 ,(concat "{" 77 ,(concat "{"
72 (let ((bongo-field-separator "")) 78 (let ((bongo-field-separator ""))
@@ -76,7 +82,19 @@
76 (bongo-formatted-infoset)) 82 (bongo-formatted-infoset))
77 (- +tab-bar-emms-max-length 2))) 83 (- +tab-bar-emms-max-length 2)))
78 "}") 84 "}")
79 bongo-pause/resume 85 (lambda () (interactive)
86 (let ((bongo-playlist-buffer
87 ;; XXX: I'm sure this is terribly inefficient
88 (cl-some (lambda (b)
89 (with-current-buffer b
90 (when-let* ((modep (derived-mode-p
91 'bongo-playlist-mode))
92 (bongo-playlist-buffer b)
93 (playingp (bongo-playing-p)))
94 b)))
95 (buffer-list))))
96 (with-bongo-playlist-buffer
97 (bongo-pause/resume))))
80 :help ,(funcall bongo-header-line-function))))) 98 :help ,(funcall bongo-header-line-function)))))
81 99
82(defvar +tab-bar-show-original nil 100(defvar +tab-bar-show-original nil