aboutsummaryrefslogtreecommitdiffstats
path: root/apps/media/js/collection.js
diff options
context:
space:
mode:
Diffstat (limited to 'apps/media/js/collection.js')
-rw-r--r--apps/media/js/collection.js22
1 files changed, 6 insertions, 16 deletions
diff --git a/apps/media/js/collection.js b/apps/media/js/collection.js
index 13eb0aff7d9..7eb027348ce 100644
--- a/apps/media/js/collection.js
+++ b/apps/media/js/collection.js
@@ -217,25 +217,15 @@ Collection={
}
},
addButtons:function(parent,data){
- buttons = parent.find('.buttons');
- if(buttons.find('.add').length<=0) {
- buttons.append('<img class="add" src="'+OC.imagePath('core','actions/play-add')+'"/>');
- }
- if(buttons.find('.play').length<=0) {
- buttons.append('<img class="play" src="'+OC.imagePath('core','actions/play')+'"/>');
- }
+ buttons = parent.find('.buttons');
+ if(buttons.find('.add').length<=0) {
+ buttons.prepend('<img class="add action" src="'+OC.imagePath('core','actions/play-add')+'" title="Add to playlist" />');
+ }
buttons.find('.add').unbind('click');
buttons.find('.add').click(function(event){
- event.preventDefault();
+ event.preventDefault();
PlayList.add(data,true);
- PlayList.render();
- });
- buttons.find('.play').unbind('click');
- buttons.find('.play').click(function(event){
- event.preventDefault();
- PlayList.add(data);
- PlayList.play(0,0);
- PlayList.render();
+ PlayList.render();
});
},
find:function(artistName,albumName,songName){