summaryrefslogtreecommitdiff
path: root/playlist.lisp
diff options
context:
space:
mode:
Diffstat (limited to 'playlist.lisp')
-rw-r--r--playlist.lisp20
1 files changed, 10 insertions, 10 deletions
diff --git a/playlist.lisp b/playlist.lisp
index c2adf97..1b55561 100644
--- a/playlist.lisp
+++ b/playlist.lisp
@@ -169,17 +169,17 @@
(defun play-this-audio (audio)
(when-let (ctl (cur-playlist-ctl audio))
- (let ((np (now-playing-track ctl)))
+ (let ((np (now-playing-track ctl))
+ (tr (track-ctl-with-audio ctl audio)))
(cond
- ((not (eq audio (audio np))) ; different track
- (let ((tr
- (track-ctl-with-audio ctl audio)))
- (stop-playback ctl)
- (setf (now-playing-track ctl) tr)
- (start-playback ctl)
- (load-now-playing-display ctl tr)))
- ((pausedp audio)
- (start-playback ctl))))))
+ ((and np (eq audio (audio np)) (pausedp audio))
+ (start-playback ctl))
+
+ (t
+ (stop-playback ctl)
+ (setf (now-playing-track ctl) tr)
+ (start-playback ctl)
+ (load-now-playing-display ctl tr))))))
;;; SYNCHRONZIED CLIENT CONTROL