aboutsummaryrefslogtreecommitdiff
path: root/emms.el
diff options
context:
space:
mode:
authorDamien Elmes <emms@repose.cx>2006-06-14 16:00:00 +0000
committerDamien Elmes <emms@repose.cx>2006-06-14 16:00:00 +0000
commitc6dbd8f17dac67fc95d4bfa6ef796073a38ff263 (patch)
tree22edf3ba1e57fcff45b5f043792acc00e6c7bfda /emms.el
parent3f741b53e67b30d556a894f5f19adc35a16a2085 (diff)
browser: refactor data format, bugfixes; emms: add emms-track-p
Subitems are now stored in a tree of "bdata" objects, which is generated when initially displaying the buffer. This makes rendering simpler and also fixes some bugs where tracks were not being sorted correctly in the browser and/or the playlist. Adding items to the playlist now inserts 'group' names when you add a whole album, artist, etc at a time. These names will be thrown away if you run emms-shuffle. The sorting routines will correctly sort the buffer, throwing away the group tags, but then throw an error because the buffer is not the size they expected it to be. Other playlist manipulation routines like next/previous should skip over the group names - if they don't, it's a bug in the playlist code. An example of the new interface is at: http://repose.cx/dump/emms-browser.png darcs-hash:20060614160048-4e3e3-82a8a0d1678b0a2d9fcfc6ca385d5b56963aedbe.gz
Diffstat (limited to 'emms.el')
-rw-r--r--emms.el5
1 files changed, 5 insertions, 0 deletions
diff --git a/emms.el b/emms.el
index e2f2fa3..0bcc686 100644
--- a/emms.el
+++ b/emms.el
@@ -504,6 +504,11 @@ whenever possible."
(run-hook-with-args 'emms-track-initialize-functions track)
track))
+(defun emms-track-p (obj)
+ "True if OBJ is an emms track."
+ (and (listp obj)
+ (eq (car obj) '*track*)))
+
(defun emms-track-type (track)
"Return the type of TRACK."
(emms-track-get track 'type))