Radio page jPlayer fixes
This commit is contained in:
parent
071de55329
commit
9dae535768
2 changed files with 29 additions and 20 deletions
|
@ -64,10 +64,10 @@
|
|||
|
||||
<div class="current-track">Now Playing: <span></span></div>
|
||||
<div class="jp-gui jp-interface">
|
||||
<ul class="jp-controls">
|
||||
<li class="ui-corner-all jp-previous">
|
||||
<ul class="jp-controls rss-buttons">
|
||||
<!--<li class="ui-corner-all jp-previous">
|
||||
<span class="icon-fast-backward icon-white" tabindex="1"><?php /*echo _("previous") */?></span>
|
||||
</li>
|
||||
</li>-->
|
||||
|
||||
<li class="ui-corner-all jp-play">
|
||||
<span class="icon-play icon-white" tabindex="1"><?php /*echo _("play") */?></span>
|
||||
|
@ -77,9 +77,9 @@
|
|||
<span class="icon-pause icon-white" tabindex="1"><?php /*echo _("pause") */?></span>
|
||||
</li>
|
||||
|
||||
<li class="ui-corner-all jp-next">
|
||||
<!--<li class="ui-corner-all jp-next">
|
||||
<span class="icon-fast-forward icon-white" tabindex="1"><?php /*echo _("next") */?></span>
|
||||
</li>
|
||||
</li>-->
|
||||
|
||||
<li class="ui-corner-all jp-stop">
|
||||
<span class="icon-stop icon-white" tabindex="1"><?php /*echo _("stop") */?></span>
|
||||
|
@ -151,9 +151,8 @@
|
|||
media_mime_supported = false;
|
||||
}
|
||||
|
||||
var playlist_item = "<li><div class='podcast_info'>";
|
||||
var podcast_title_link = "<a class='podcast_title jp-playlist-item' tabindex='0' href='#'>"+value.CcFiles.track_title+"</a>";
|
||||
var podcast_title_no_link = "<div class='podcast_title jp-playlist-item' tabindex='0' href='#'>"+value.CcFiles.track_title+"</div>";
|
||||
var podcast_title_no_link = "<div class='podcast_title'>"+value.CcFiles.track_title+"</div>";
|
||||
var playlist_metadata = "<span class='podcast_date'>"+value.publication_date+"</span>" +
|
||||
"<span class='podcast_length'>"+value.CcFiles.length+"</span>" +
|
||||
"<span class='podcast_desc_btn'>Description</span>" +
|
||||
|
@ -163,18 +162,21 @@
|
|||
// we only add the track to the jPlayer playlist if it can be played by jPlayer
|
||||
playlist.push(media);
|
||||
|
||||
var playlist_item = "<li class='jp-playlist-item'><div class='podcast_info'>";
|
||||
|
||||
playlist_item += podcast_title_link + playlist_metadata;
|
||||
|
||||
playlist_item += "<div class='podcast_btn_group'>"+
|
||||
"<span class='podcast_play podcast_action_btn'><a href='#' id='rss-track' data-rss-playlist-id='"+index+"'><img src='css/radio-page/img/podcast_play.png'></a></span>" +
|
||||
"<span class='podcast_download podcast_action_btn'><a id='rss-download-link' href='"+value.download_url+"'><img src='css/radio-page/img/podcast_download.png'></a></span> </div></div></li>";
|
||||
|
||||
} else {
|
||||
//TODO fix this
|
||||
playlist.push({});
|
||||
var playlist_item = "<div class='playlist-item-no-preview podcast_info'>";
|
||||
playlist_item += podcast_title_no_link + playlist_metadata;
|
||||
playlist_item += "<div class='podcast_btn_group'>"+
|
||||
"<span class='podcast_no_play'><img src='css/radio-page/img/podcast_no_play.png'></span>" +
|
||||
"<span class='podcast_download podcast_action_btn'><a id='rss-download-link' href='"+value.download_url+"'><img src='css/radio-page/img/podcast_download.png'></a></span> </div></div></li>";
|
||||
"<span class='podcast_download podcast_action_btn'><a id='rss-download-link' href='"+value.download_url+"'><img src='css/radio-page/img/podcast_download.png'></a></span> </div></div>";
|
||||
}
|
||||
|
||||
$('.rss-tracks ul').append(playlist_item);
|
||||
|
@ -197,14 +199,14 @@
|
|||
//$(".podcast_info>a.jp-playlist-current").removeClass('jp-playlist-current');
|
||||
//$(".jp-playlist>li.jp-playlist-current").removeClass('jp-playlist-current');
|
||||
|
||||
/*$('.podcast_play').on('click', function() {
|
||||
$('.podcast_play').on('click', function() {
|
||||
_playlist_jplayer.play($(this).find('#rss-track').attr('data-rss-playlist-id'));
|
||||
|
||||
// we need to manually highlight the track that play was clicked on
|
||||
$(this).parents('li').addClass('jp-playlist-current');
|
||||
|
||||
return false;
|
||||
});*/
|
||||
});
|
||||
|
||||
$('.podcast_desc_btn').click(function(){
|
||||
$(this).toggleClass('current');
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue