'</td><td></td></tr>'
);
break;
- case 'wrap':
+ case 'plist_entry':
+ var clazz = 'plist_entry';
+ $('#salamisandwich > tbody').append(
+ '<tr uri="' +
+ encodeURIComponent(obj.data[item].uri) +
+ '" class="' + clazz + '">' +
+ '<td><span class="glyphicon glyphicon-music"></span></td>' +
+ '<td colspan="5">' +
+ obj.data[item].title +
+ '</td>' +
+ '</tr>'
+ );
+ break;
+ case 'wrap':
if (current_app == 'browse') {
$('#next').removeClass('hide');
} else {
'MPD_API_ADD_PLAY_TRACK',
'play'
);
+ appendClickableIcon(
+ $(
+ '#salamisandwich > tbody > tr.plist_entry > td:last-child'
+ ),
+ 'MPD_API_ADD_PLAY_TRACK',
+ 'play'
+ );
} else {
$('#salamisandwich > tbody > tr').on({
mouseenter: function () {
'MPD_API_ADD_PLAY_TRACK',
'play'
);
+ else if ($(this).is('.plist_entry'))
+ appendClickableIcon(
+ $(this).children().last(),
+ 'MPD_API_ADD_PLAY_TRACK',
+ 'play'
+ );
},
mouseleave: function () {
$(this)
case MPD_ENTITY_TYPE_SONG:
song = mpd_entity_get_song(entity);
- cur += json_emit_raw_str(cur, end - cur, "{\"type\":\"song\",\"uri\":");
+ cur += json_emit_raw_str(cur, end - cur, "{\"type\":\"plist_entry\",\"uri\":");
cur += json_emit_quoted_str(cur, end - cur, mpd_song_get_uri(song));
cur += json_emit_raw_str(cur, end - cur, ",\"album\":");
cur += json_emit_quoted_str(cur, end - cur, mpd_get_album(song));