diff options
-rw-r--r-- | emms-browser.el | 10 | ||||
-rw-r--r-- | emms-player-vlc.el | 7 | ||||
-rw-r--r-- | emms.el | 2 |
3 files changed, 11 insertions, 8 deletions
diff --git a/emms-browser.el b/emms-browser.el index 1ae727b..fcb4ef3 100644 --- a/emms-browser.el +++ b/emms-browser.el @@ -190,10 +190,12 @@ ;; artist->track instead of artist->album->track when you switch to ;; the 'singles' filter. -;; (defadvice emms-browser-next-mapping-type -;; (after no-album (current-mapping)) -;; (when (eq ad-return-value 'info-album) -;; (setq ad-return-value 'info-title))) +;; (advice-add 'emms-browser-next-mapping-type :around #'my-emms--types) +;; (defun my-emms--types (orig-fun &rest args) +;; (let ((type (apply orig-fun args))) +;; (if (eq type 'info-album) +;; 'info-title) +;; type))) ;; (defun toggle-album-display () ;; (if (string= emms-browser-current-filter-name "singles") diff --git a/emms-player-vlc.el b/emms-player-vlc.el index 7a502cd..060f0d8 100644 --- a/emms-player-vlc.el +++ b/emms-player-vlc.el @@ -43,14 +43,15 @@ ;; track, so the player sentinel has no way of telling that the next ;; track should be played. Therefore I redefine this low-level ;; function and add a "quit" track which is invisible to Emms. -(defadvice emms-player-vlc-start (around quit-vlc-after-finish activate) - (let ((process (apply 'start-process +(advice-add 'emms-player-vlc-start :override #'emms--vlc-quit-after-finish) +(defun emms--vlc-quit-after-finish (track &rest _) + (let ((process (apply #'start-process emms-player-simple-process-name nil emms-player-vlc-command-name ;; splice in params here (append emms-player-vlc-parameters - (list (emms-track-name (ad-get-arg 0))) + (list (emms-track-name track)) '("vlc://quit"))))) ;; Add a sentinel for signaling termination. (set-process-sentinel process #'emms-player-simple-sentinel)) @@ -7,7 +7,7 @@ ;; Version: 7.1 ;; Keywords: emms, mp3, ogg, flac, music, mpeg, video, multimedia ;; Package-Type: multi -;; Package-Requires: ((cl-lib "0.5") (seq)) +;; Package-Requires: ((cl-lib "0.5") (nadvice "0.3") (seq)) ;; url: https://www.gnu.org/software/emms/ ;; This file is part of EMMS. |