summaryrefslogtreecommitdiffhomepage
path: root/lib
diff options
context:
space:
mode:
authorjao <jao@gnu.org>2024-11-07 18:02:38 +0000
committerjao <jao@gnu.org>2024-11-07 18:02:38 +0000
commit8ddc2d688cd37693320e46aa3d35d72f06e5bab3 (patch)
tree2bd00b628e8d694d48f4de35df3297a6d58c010a /lib
parentae54b20761539fdbf16689cfa6bb8b3e5b13c251 (diff)
downloadelibs-8ddc2d688cd37693320e46aa3d35d72f06e5bab3.tar.gz
elibs-8ddc2d688cd37693320e46aa3d35d72f06e5bab3.tar.bz2
random-album: orthogonal notifications
Diffstat (limited to 'lib')
-rw-r--r--lib/media/jao-mpc.el3
-rw-r--r--lib/media/jao-random-album.el12
2 files changed, 5 insertions, 10 deletions
diff --git a/lib/media/jao-mpc.el b/lib/media/jao-mpc.el
index 52fdfbf..ab8823f 100644
--- a/lib/media/jao-mpc.el
+++ b/lib/media/jao-mpc.el
@@ -311,8 +311,7 @@
(setq jao-lyrics-info-function #'jao-mpc-lyrics-track-data)
(jao-random-album-setup #'jao-mpc--album-buffer
#'jao-mpc--add-and-play
- #'jao-mpc-stop
- jao-notify-audio-icon)
+ #'jao-mpc-stop)
(let ((jao-random-album-active nil)) (jao-mpc-connect))
(when secondary-port (jao-mpc-connect secondary-port))
(when priority
diff --git a/lib/media/jao-random-album.el b/lib/media/jao-random-album.el
index 5b10308..3b2915b 100644
--- a/lib/media/jao-random-album.el
+++ b/lib/media/jao-random-album.el
@@ -18,13 +18,10 @@
;; You should have received a copy of the GNU General Public License
;; along with this program. If not, see <http://www.gnu.org/licenses/>.
-(require 'jao-notify)
-
(defvar jao-random-album-active t)
(defvar jao-random-lines nil)
(defvar jao-random-lines-file (expand-file-name "~/.emacs.d/random-lines"))
-(defvar jao-random-album-notify t)
-(defvar jao-random-album-notify-icon jao-notify-audio-icon)
+(defvar jao-random-album-notify nil)
(defvar jao-random-album-skip-lines 2)
(defun jao-random-lines ()
@@ -81,18 +78,17 @@
(let ((album (string-trim (thing-at-point 'line))))
(funcall jao-random-album-add-tracks-and-play album)
(when jao-random-album-notify
- (jao-notify album "Next album" jao-random-album-notify-icon)))))
+ (funcall jao-random-album-notify album)))))
(defun jao-random-album-reset ()
(interactive)
(setq jao-random-lines nil)
(jao-random-lines-save))
-(defun jao-random-album-setup (album-buffer add-and-play stop &optional icon)
+(defun jao-random-album-setup (album-buffer add-and-play stop)
(setq jao-random-album-buffer album-buffer
jao-random-album-add-tracks-and-play add-and-play
- jao-random-album-stop stop
- jao-random-album-notify-icon icon))
+ jao-random-album-stop stop))
(provide 'jao-random-album)