aboutsummaryrefslogtreecommitdiff
path: root/emms-player-mpd.el
diff options
context:
space:
mode:
authorMichael Olson <mwolson@gnu.org>2006-04-09 00:35:00 +0000
committerMichael Olson <mwolson@gnu.org>2006-04-09 00:35:00 +0000
commit2d70d0a638b8b1f790674ef7e31efb44ca671b0d (patch)
tree9af580dc01d4e04ba9079d6b6781b4c356f856dd /emms-player-mpd.el
parentd03e7d69061e98ae1b807a5a3e57ba4bd4e72885 (diff)
emms-source-playlist: Get things working to my satisfaction, like saving playlists in different formats and (optionally) being prompted for which format.
darcs-hash:20060409003540-1bfb2-4aedadb4bc109afb1aaf6b96530e61d6a9f19201.gz
Diffstat (limited to 'emms-player-mpd.el')
-rw-r--r--emms-player-mpd.el18
1 files changed, 8 insertions, 10 deletions
diff --git a/emms-player-mpd.el b/emms-player-mpd.el
index 5dac00a..821b8ab 100644
--- a/emms-player-mpd.el
+++ b/emms-player-mpd.el
@@ -523,16 +523,14 @@ This handles both m3u and pls type playlists."
(with-temp-buffer
(insert-file-contents playlist)
(goto-char (point-min))
- (let ((list (cond ((emms-source-playlist-m3u-p)
- (emms-source-playlist-parse-m3u-1))
- ((emms-source-playlist-pls-p)
- (emms-source-playlist-parse-pls-1))
- (t nil)))
- (any-success nil))
- (dolist (file list)
- (when (emms-player-mpd-add-file file)
- (setq any-success t)))
- any-success)))
+ (let ((format (emms-source-playlist-determine-format)))
+ (when format
+ (let ((list (emms-source-playlist-files format))
+ (any-success nil))
+ (dolist (file list)
+ (when (emms-player-mpd-add-file file)
+ (setq any-success t)))
+ any-success)))))
(defun emms-player-mpd-add (track)
"Add TRACK to the MusicPD playlist."