diff options
author | Jon Bergli Heier <snakebite@jvnv.net> | 2012-12-19 23:20:21 +0100 |
---|---|---|
committer | Jon Bergli Heier <snakebite@jvnv.net> | 2012-12-19 23:20:21 +0100 |
commit | 1134dc1efa6a4326424cf7b1271cb4465afb712d (patch) | |
tree | d2b7133c3b241a0428cb563d722d2ee4980eb146 /static/playlist.js | |
parent | 3ceac273c13435e39cfd84b990e5c4ae728fcfbf (diff) |
Allow double clicking on selectable items.
Track items can still be selected by single clicking, this is now done
manually. Double clicking will add the track to the playlist. Single
clicking on album names will open an album view for that album.
Diffstat (limited to 'static/playlist.js')
-rw-r--r-- | static/playlist.js | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/static/playlist.js b/static/playlist.js index 70149b3..bd323d3 100644 --- a/static/playlist.js +++ b/static/playlist.js @@ -24,6 +24,14 @@ $(function(){ playsound(model); return false; }); + $('a.album', this.el).click(function() { + var album = { + id: model.attributes.metadata.album_id, + name: model.attributes.metadata.album + }; + show_album(album); + return false; + }); $('a.delete', this.el).click(function() { items.remove(model); playlist.hintnext(); |