1
0
Fork 0
mirror of https://github.com/jellyfin/jellyfin-web synced 2025-03-30 19:56:21 +00:00

live tv updates

This commit is contained in:
Luke Pulverenti 2013-12-21 13:37:34 -05:00
parent 97a67a7cf8
commit ac4c65ac9a
23 changed files with 318 additions and 156 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 211 KiB

View file

@ -113,7 +113,7 @@
}
.libraryPage, .libraryPage .itemListContent {
background: #494949 url(images/bgflip.png) repeat-x!important;
background: #252525 repeat-x!important;
background-attachment: fixed!important;
}
@ -123,7 +123,8 @@
.listHeader {
margin-top: .5em;
margin-bottom: 5px;
margin-bottom: 0;
padding-left: 4px;
}
.libraryViewNav {
@ -149,7 +150,7 @@
}
.ehsContent {
max-width: 600px;
max-width: 620px;
margin: 0 auto;
padding: 0;
border-spacing: 0;
@ -344,6 +345,10 @@ a.itemTag:hover {
left: .8em;
}
.itemCommunityRating + .userDataIcons {
margin-left: 1.5em;
}
.itemBackdrop {
background-size: cover;
background-position: center 15%;
@ -408,6 +413,11 @@ a.itemTag:hover {
box-shadow: 0px 0 20px #000;
border: solid 1px #222;
margin-top: -20px;
margin-bottom: 5px;
}
.noBackdrop .itemDetailImage {
margin-top: 0;
}
.itemDetailGalleryLink img:hover {
@ -447,6 +457,17 @@ a.itemTag:hover {
text-overflow: ellipsis;
}
.mobileOverview {
display: none;
padding: 0 .5em;
max-height: initial;
}
.mobileGenres {
display: none;
padding: 0 .5em;
}
.libraryPage ::-webkit-scrollbar {
width: 12px;
height: 12px;
@ -476,8 +497,8 @@ a.itemTag:hover {
padding: .5em .75em;
font-size: 16px;
font-weight: normal;
border: 1px solid #181818;
background: #222;
border: 1px solid #000;
background: #111;
white-space: nowrap;
text-overflow: ellipsis;
overflow: hidden;
@ -509,20 +530,55 @@ a.itemTag:hover {
.itemBackdrop {
background-image: none!important;
height: 510px;
}
.itemImageContainer {
position: absolute;
top: -230px;
margin: 0 auto 0 -20px;
text-align: center;
left: 0;
width: 100%;
height: auto;
}
.noBackdrop {
height: 510px;
height: auto;
}
.itemBackdropContent {
position: static;
padding: 1em 1em 0;
background-color: transparent;
}
.parentName {
position: static;
}
.itemDetailImage {
max-height: 240px;
max-width: 100px;
margin-top: 0;
}
.mobileOverview, .mobileGenres {
display: block;
}
.desktopOverview, .desktopGenres {
display: none;
}
.inlineItemName {
font-size: 18px;
}
.inlineItemName + .itemMiscInfo {
margin-left: 0!important;
margin-top: 1em;
display: block!important;
}
.primaryDetailPageContent p:first-child {
margin-top: 0;
}
.primaryDetailPageContent .userDataIcons {
margin-left: 0!important;
margin-top: 1.5em;
display: block;
}
}
@ -585,7 +641,7 @@ a.itemTag:hover {
@media all and (min-width: 1000px) {
.ehsContent {
max-width: 800px;
max-width: 820px;
}
.detailPageContent {
@ -593,14 +649,14 @@ a.itemTag:hover {
}
.primaryDetailPageContent {
max-width: 800px;
max-width: 850px;
}
}
@media all and (min-width: 1200px) {
.ehsContent {
max-width: 940px;
max-width: 950px;
}
.detailPageContent {
@ -608,7 +664,7 @@ a.itemTag:hover {
}
.primaryDetailPageContent {
max-width: 800px;
max-width: 900px;
}
}
@ -623,7 +679,7 @@ a.itemTag:hover {
}
.ehsContent {
max-width: 1070px;
max-width: 1080px;
}
}
@ -649,7 +705,6 @@ a.itemTag:hover {
.itemMiscInfo {
color: #ddd;
white-space: nowrap;
text-overflow: ellipsis;
overflow: hidden;
}
@ -818,10 +873,10 @@ a.itemTag:hover {
.alphabetPicker {
position: fixed;
right: 2px;
right: 1px;
bottom: 0;
top: 100px;
width: 27px;
width: 20px;
z-index: 1000;
text-align: center;
font-size: 14px;
@ -853,7 +908,7 @@ a.itemTag:hover {
}
.itemsContainerWithAlphaPicker {
margin-right: 27px;
margin-right: 10px;
}
}

View file

@ -81,3 +81,41 @@
.tvProgram:hover, .tvProgram:hover .tvProgramInfo {
background-color: #4d90fe;
}
.timerCircle {
display: inline-block;
width: 16px;
height: 16px;
border-radius: 50%;
background: #cc0000;
vertical-align: top;
border: 1px solid #cc3333;
margin-left: 1em;
}
.seriesTimerCircle {
position: relative;
margin-left: 0;
left: 30px;
opacity: .3;
margin-left: 1em;
}
.seriesTimerCircle + .seriesTimerCircle {
opacity: .65;
left: 0;
margin-left: 0;
}
.seriesTimerCircle + .seriesTimerCircle + .seriesTimerCircle {
opacity: 1;
left: -30px;
margin-left: 0;
}
.channelImageContainer .itemDetailImage {
max-width: 160px;
max-height: 100px;
margin-top: 1em;
margin-bottom: 1em;
}

View file

@ -1,5 +1,5 @@
.posterItem {
margin: 3px;
margin: 6px;
text-shadow: none;
font-weight: normal!important;
display: inline-block;
@ -8,7 +8,6 @@
text-decoration: none;
text-align: left;
overflow: hidden;
border: 1px solid #555;
}
.posterItem:hover {
@ -46,14 +45,17 @@
padding-left: 2px;
}
.posterItemTextContainer {
}
.posterItemText {
text-overflow: ellipsis;
overflow: hidden;
text-wrap: none;
white-space: nowrap;
padding: 5px 4px 4px;
background: #181818;
padding: 6px 5px 5px;
background: #111;
text-shadow: none;
}
@ -63,7 +65,6 @@
.posterItemText + .posterItemText {
padding-top: 2px;
border-top: 0;
}
.posterItemText + .posterItemProgress {
@ -122,11 +123,6 @@
.portraitPosterItem {
width: 100px;
border-color: #555;
}
.smallBackdropPosterItem {
border-color: #555;
}
.portraitPosterItem .posterItemImage {

View file

@ -716,7 +716,7 @@ progress {
.imgUserItemRating {
height: 16px;
width: 16px;
margin-right: 1em;
margin-right: .75em;
cursor: pointer;
vertical-align: top;
}

View file

@ -1,5 +1,5 @@
.tileItem {
background: #333;
background: #1e1e1e;
padding: 10px 7px 5px;
margin: 3px 0;
font-weight: normal!important;
@ -38,7 +38,7 @@
}
.defaultTileImage {
background-color: #999;
background-color: #555;
}
.tileItem p {

View file

@ -126,15 +126,16 @@
<p><span class="itemName inlineItemName"></span><span class="itemMiscInfo" style="display: inline;"></span></p>
<p>
<span class="itemCommunityRating"></span>
<span class="userDataIcons" style="margin-left: 2em;"></span>
<span class="userDataIcons"></span>
</p>
<p class="itemGenres"></p>
<p class="itemOverview"></p>
<p class="itemOverview desktopOverview"></p>
<p id="itemBirthday"></p>
</td>
</tr>
</table>
</div>
<p class="itemOverview mobileOverview"></p>
</div>
<div class="ui-body-a" style="text-align: center; padding: .25em 0 .5em;">
<span id="playButtonContainer" style="display: none;">

View file

@ -117,17 +117,19 @@
<p><span class="itemName inlineItemName"></span><span class="itemMiscInfo" style="display: inline;"></span></p>
<p>
<span class="itemCommunityRating"></span>
<span class="userDataIcons" style="margin-left: 2em;"></span>
<span class="userDataIcons"></span>
</p>
<p id="artist"></p>
<p class="itemGenres"></p>
<p class="itemOverview"></p>
<p class="itemGenres desktopGenres"></p>
<p class="itemOverview desktopOverview"></p>
</td>
</tr>
</table>
</div>
<a href="#" id="lnkPreviousItem" class="lnkPreviousItem lnkSibling hide">← Previous</a>
<a href="#" id="lnkNextItem" class="lnkNextItem lnkSibling hide">Next →</a>
<p class="itemGenres mobileGenres"></p>
<p class="itemOverview mobileOverview"></p>
</div>
<div class="ui-body-a" style="text-align: center; padding: .25em 0 .5em;">
<span id="missingIndicator" style="margin-left: .5em; display: none;">

View file

@ -12,12 +12,10 @@
<a href="livetvtimers.html">Schedule</a>
<a href="livetvseriestimers.html">Series</a>
</div>
<div id="itemBackdrop" class="itemBackdrop noBackdrop">
<div class="itemBackdropContent">
<table class="detailPageContent primaryDetailPageContent">
<tr>
<td style="vertical-align: top; padding: 0 1em 0 0;">
<div id="itemImage" class="itemImageContainer"></div>
<div id="itemImage" class="itemImageContainer channelImageContainer"></div>
</td>
<td style="vertical-align: top; padding: 0;">
<p><span class="itemName inlineItemName"></span><span class="itemMiscInfo" style="display: inline;"></span></p>
@ -28,8 +26,6 @@
</td>
</tr>
</table>
</div>
</div>
<div class="ui-body-a" style="text-align: center; padding: .25em 0 .5em;">
<span id="playButtonContainer" style="display: none;">
<button id="btnPlay" type="button" data-icon="play" data-inline="true" data-mini="true">Play</button>

View file

@ -22,27 +22,27 @@
<td style="vertical-align: top; padding: 0;">
<p><span class="itemName inlineItemName"></span><span class="itemMiscInfo" style="display: inline;"></span></p>
<p class="itemEpisodeName"></p>
<p class="itemMiscInfo miscTvProgramInfo"></p>
<p>
<span class="itemCommunityRating"></span>
<span class="userDataIcons"></span>
</p>
<p class="itemGenres"></p>
<p class="itemOverview"></p>
<p class="itemGenres desktopGenres"></p>
<p class="itemOverview desktopOverview"></p>
</td>
</tr>
</table>
</div>
<p class="itemGenres mobileGenres"></p>
<p class="itemOverview mobileOverview"></p>
</div>
<div class="ui-body-a" style="text-align: center; padding: .25em 0 .5em;">
<span id="playButtonContainer" style="display: none;">
<button id="btnPlay" type="button" data-icon="play" data-inline="true" data-mini="true">Play</button>
<span id="recordButtonContainer" style="display: none;">
<button id="btnRecord" type="button" data-icon="facetime-video" data-inline="true" data-mini="true">Record</button>
</span>
<span>
<button id="btnRemote" type="button" data-icon="hand-up" data-inline="true" data-mini="true">Remote</button>
</span>
<span id="deleteButtonContainer" style="display: none;">
<button id="btnDelete" type="button" data-icon="delete" data-inline="true" data-mini="true">Delete</button>
</span>
</div>
<div data-role="content">
<div class="detailPageContent">
@ -54,8 +54,7 @@
<div class="detailSectionContent" style="padding: 0 1em;">
<p class="status"></p>
<p class="itemChannelNumber"></p>
<p class="audio"></p>
<p class="airDate"></p>
</div>
</div>
</div>

View file

@ -22,16 +22,19 @@
<td style="vertical-align: top; padding: 0;">
<p><span class="itemName inlineItemName"></span><span class="itemMiscInfo" style="display: inline;"></span></p>
<p class="itemEpisodeName"></p>
<p class="itemMiscInfo miscTvProgramInfo"></p>
<p>
<span class="itemCommunityRating"></span>
<span class="userDataIcons"></span>
</p>
<p class="itemGenres"></p>
<p class="itemOverview"></p>
<p class="itemGenres desktopGenres"></p>
<p class="itemOverview desktopOverview"></p>
</td>
</tr>
</table>
</div>
<p class="itemGenres mobileGenres"></p>
<p class="itemOverview mobileOverview"></p>
</div>
<div class="ui-body-a" style="text-align: center; padding: .25em 0 .5em;">
<span id="playButtonContainer" style="display: none;">
@ -54,8 +57,7 @@
<div class="detailSectionContent" style="padding: 0 1em;">
<p class="status"></p>
<p class="itemChannelNumber"></p>
<p class="audio"></p>
<p class="airDate"></p>
</div>
</div>
</div>

View file

@ -183,7 +183,7 @@
$('#scenesCollapsible', page).hide();
} else {
$('#scenesCollapsible', page).show();
renderScenes(page, item, 6);
renderScenes(page, item, 5);
}
if (!item.LocalTrailerCount && !item.RemoteTrailers.length) {
$('#trailersCollapsible', page).addClass('hide');

View file

@ -213,6 +213,10 @@
return "<img src='css/images/clients/mbkinect.png' alt='MB Kinect' />";
}
if (clientLowered == "xbmc") {
return "<img src='css/images/clients/xbmc.png' alt='Xbmc' />";
}
return connection.Client;
},

View file

@ -33,14 +33,15 @@
var checkSortOption = $('.radioSortBy:checked', page);
$('.viewSummary', page).html(LibraryBrowser.getViewSummaryHtml(query, checkSortOption)).trigger('create');
if (view == "Poster") {
html += LibraryBrowser.getPosterDetailViewHtml({
html += LibraryBrowser.getPosterViewHtml({
items: result.Items,
context: "tv",
shape: "backdrop"
useAverageAspectRatio: true,
shape: "backdrop",
showTitle: true,
showParentTitle: true
});
$('.itemsContainer', page).removeClass('timelineItemsContainer');
}
html += LibraryBrowser.getPagingHtml(query, result.TotalRecordCount);

View file

@ -327,7 +327,7 @@
try {
var birthday = parseISO8601Date(item.PremiereDate, { toLocal: true }).toDateString();
$('#itemBirthday', page).show().html("Birthday:&nbsp;&nbsp;" + birthday);
$('#itemBirthday', page).show().html("Born:&nbsp;&nbsp;" + birthday);
}
catch (err) {
$('#itemBirthday', page).hide();
@ -341,7 +341,7 @@
try {
var deathday = parseISO8601Date(item.EndDate, { toLocal: true }).toDateString();
$('#itemDeathDate', page).show().html("Death day:&nbsp;&nbsp;" + deathday);
$('#itemDeathDate', page).show().html("Died:&nbsp;&nbsp;" + deathday);
}
catch (err) {
$('#itemBirthday', page).hide();

View file

@ -1,6 +1,6 @@
var LibraryBrowser = (function (window, document, $, screen, localStorage) {
var defaultBackground = "#999;";
var defaultBackground = "#555;";
return {
@ -867,9 +867,9 @@
if (options.showParentTitle) {
html += "<div class='" + cssclass + "'>";
html += "<div class='" + cssclass + "'><b>";
html += item.SeriesName || item.Album || "&nbsp;";
html += "</div>";
html += "</b></div>";
}
if (options.showTitle) {
@ -1983,6 +1983,11 @@
text = date.toLocaleDateString();
miscInfo.push(text);
if (item.Type != "Recording") {
text = LiveTvHelpers.getDisplayTime(date);
miscInfo.push(text);
}
}
catch (e) {
console.log("Error parsing date: " + item.PremiereDate);
@ -2057,18 +2062,6 @@
miscInfo.push(item.OfficialRating);
}
if (item.Type == "Recording") {
if (item.IsHD) {
miscInfo.push("HD");
}
if (item.IsRepeat) {
miscInfo.push("Repeat");
}
}
if (item.Video3DFormat) {
miscInfo.push("3D");
}
@ -2080,7 +2073,7 @@
var overview = item.OverviewHtml || item.Overview || '';
elem.html(overview).show().trigger('create');
elem.html(overview).trigger('create');
$('a', elem).each(function () {
$(this).attr("target", "_blank");
@ -2114,11 +2107,11 @@
renderGenres: function (elem, item, context) {
if (item.Genres && item.Genres.length) {
var html = '';
for (var i = 0, length = item.Genres.length; i < length; i++) {
var genres = item.Genres || [];
for (var i = 0, length = genres.length; i < length; i++) {
if (i > 0) {
html += '&nbsp;&nbsp;/&nbsp;&nbsp;';
@ -2130,15 +2123,10 @@
param = "gamegenre";
}
html += '<a class="textlink" href="itembynamedetails.html?context=' + context + '&' + param + '=' + ApiClient.encodeName(item.Genres[i]) + '">' + item.Genres[i] + '</a>';
html += '<a class="textlink" href="itembynamedetails.html?context=' + context + '&' + param + '=' + ApiClient.encodeName(genres[i]) + '">' + genres[i] + '</a>';
}
elem.show().html(html).trigger('create');
} else {
elem.hide();
}
elem.html(html).trigger('create');
},
renderPremiereDate: function (elem, item) {

View file

@ -101,6 +101,16 @@
html += minutes;
}
if (program.SeriesTimerId) {
html += '<div class="timerCircle seriesTimerCircle"></div>';
html += '<div class="timerCircle seriesTimerCircle"></div>';
html += '<div class="timerCircle seriesTimerCircle"></div>';
}
else if (program.TimerId) {
html += '<div class="timerCircle"></div>';
}
html += '</div>';
html += '</div>';
@ -234,6 +244,61 @@
date = date.replace('0:00', '0').replace(':00 ', '').replace(' ', '');
return date;
},
renderMiscProgramInfo: function(elem, obj) {
var html = [];
if (obj.IsSeries && !obj.IsRepeat) {
html.push('<span class="newTvProgram">NEW</span>');
}
if (obj.IsLive) {
html.push('<span class="liveTvProgram">LIVE</span>');
}
if (obj.ChannelId) {
html.push('<a class="textlink" href="livetvchannel.html?id=' + obj.ChannelId + '">' + obj.ChannelName + '</a>');
}
if (obj.IsHD) {
html.push('HD');
}
if (obj.Audio) {
html.push(obj.Audio);
}
elem.html(html.join('&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;')).trigger('create');
},
renderOriginalAirDate: function(elem, item) {
var airDate = item.OriginalAirDate;
if (airDate) {
try {
airDate = parseISO8601Date(airDate, { toLocal: true }).toLocaleDateString();
}
catch (e) {
console.log("Error parsing date: " + airDate);
}
elem.html('Original air date:&nbsp;&nbsp;' + airDate).show();
} else {
elem.hide();
}
}
};

View file

@ -11,11 +11,7 @@
$('.itemName', page).html(program.Name);
$('.itemChannelNumber', page).html('Channel:&nbsp;&nbsp;&nbsp;<a href="livetvchannel.html?id=' + program.ChannelId + '">' + program.ChannelName + '</a>').trigger('create');
if (program.EpisodeTitle) {
$('.itemEpisodeName', page).html('Episode:&nbsp;&nbsp;&nbsp;' + program.EpisodeTitle);
} else {
$('.itemEpisodeName', page).html('');
}
$('.itemEpisodeName', page).html(program.EpisodeTitle || '');
if (program.CommunityRating) {
$('.itemCommunityRating', page).html(LibraryBrowser.getRatingHtml(program)).show();
@ -166,7 +162,9 @@
$('#btnCancel', page).on('click', function () {
Dashboard.navigate('livetvchannel.html?id=' + currentProgram.ChannelId);
var programId = getParameterByName('programid');
Dashboard.navigate('livetvprogram.html?id=' + programId);
});

View file

@ -18,13 +18,8 @@
Dashboard.setPageTitle(name);
$('.itemName', page).html(name);
$('.itemChannelNumber', page).html('Channel:&nbsp;&nbsp;&nbsp;<a href="livetvchannel.html?id=' + item.ChannelId + '">' + item.ChannelName + '</a>').trigger('create');
if (item.EpisodeTitle) {
$('.itemEpisodeName', page).html('Episode:&nbsp;&nbsp;&nbsp;' + item.EpisodeTitle);
} else {
$('.itemEpisodeName', page).html('');
}
$('.itemEpisodeName', page).html(item.EpisodeTitle || '');
if (item.CommunityRating) {
$('.itemCommunityRating', page).html(LibraryBrowser.getRatingHtml(item)).show();
@ -38,6 +33,8 @@
LibraryBrowser.renderOverview($('.itemOverview', page), item);
$('.itemMiscInfo', page).html(LibraryBrowser.getMiscInfoHtml(item));
LiveTvHelpers.renderMiscProgramInfo($('.miscTvProgramInfo', page), item);
if (ApiClient.isWebSocketOpen()) {
var vals = [item.Type, item.Id, item.Name];
@ -47,6 +44,8 @@
ApiClient.sendWebSocketMessage("Context", vals.join('|'));
}
$('#recordButtonContainer', page).show();
if (MediaPlayer.canPlay(item)) {
$('#playButtonContainer', page).show();
} else {
@ -63,6 +62,8 @@
});
LiveTvHelpers.renderOriginalAirDate($('.airDate', page), item);
Dashboard.hideLoadingMsg();
});
}
@ -71,6 +72,14 @@
var page = this;
$('#btnRecord', page).on('click', function() {
var id = getParameterByName('id');
Dashboard.navigate('livetvnewrecording.html?programid=' + id);
});
}).on('pageshow', "#liveTvProgramPage", function () {
var page = this;

View file

@ -21,6 +21,15 @@
});
}
function play() {
var userdata = currentItem.UserData || {};
var mediaType = currentItem.MediaType;
LibraryBrowser.showPlayMenu(this, currentItem.Id, currentItem.Type, mediaType, userdata.PlaybackPositionTicks);
}
function renderRecording(page, item) {
currentItem = item;
@ -33,13 +42,8 @@
Dashboard.setPageTitle(name);
$('.itemName', page).html(name);
$('.itemChannelNumber', page).html('Channel:&nbsp;&nbsp;&nbsp;<a href="livetvchannel.html?id=' + item.ChannelId + '">' + item.ChannelName + '</a>').trigger('create');
if (item.EpisodeTitle) {
$('.itemEpisodeName', page).html('Episode:&nbsp;&nbsp;&nbsp;' + item.EpisodeTitle);
} else {
$('.itemEpisodeName', page).html('');
}
$('.itemEpisodeName', page).html(item.EpisodeTitle || '');
if (item.CommunityRating) {
$('.itemCommunityRating', page).html(LibraryBrowser.getRatingHtml(item)).show();
@ -53,6 +57,8 @@
LibraryBrowser.renderOverview($('.itemOverview', page), item);
$('.itemMiscInfo', page).html(LibraryBrowser.getMiscInfoHtml(item));
LiveTvHelpers.renderMiscProgramInfo($('.miscTvProgramInfo', page), item);
if (ApiClient.isWebSocketOpen()) {
var vals = [item.Type, item.Id, item.Name];
@ -70,12 +76,6 @@
$('.status', page).html('Status:&nbsp;&nbsp;&nbsp;' + item.Status);
if (item.Audio) {
$('.audio', page).html('Audio:&nbsp;&nbsp;&nbsp;' + item.Audio).show();
} else {
$('.audio', page).hide();
}
Dashboard.getCurrentUser().done(function (user) {
if (user.Configuration.IsAdministrator && item.LocationType !== "Offline") {
@ -86,6 +86,8 @@
});
LiveTvHelpers.renderOriginalAirDate($('.airDate', page), item);
Dashboard.hideLoadingMsg();
}
@ -107,6 +109,7 @@
var page = this;
$('#btnDelete', page).on('click', deleteRecording);
$('#btnPlay', page).on('click', play);
}).on('pagebeforeshow', "#liveTvRecordingPage", function () {

View file

@ -480,18 +480,21 @@
// Account for screen rotation. Use the larger dimension as the width.
var screenWidth = Math.max(screen.height, screen.width);
var mediaStreams = item.MediaStreams || [];
var baseParams = {
audioChannels: 2,
audioBitrate: 128000,
videoBitrate: 2000000,
maxWidth: Math.min(screenWidth, 1280),
StartTimeTicks: 0,
SubtitleStreamIndex: getInitialSubtitleStreamIndex(item.MediaStreams, user),
AudioStreamIndex: getInitialAudioStreamIndex(item.MediaStreams, user),
deviceId: ApiClient.deviceId()
SubtitleStreamIndex: getInitialSubtitleStreamIndex(mediaStreams, user),
AudioStreamIndex: getInitialAudioStreamIndex(mediaStreams, user),
deviceId: ApiClient.deviceId(),
Type: item.Type
};
var videoStream = item.MediaStreams.filter(function (i) {
var videoStream = mediaStreams.filter(function (i) {
return i.Type == "Video";
})[0];
@ -573,7 +576,7 @@
$('#qualityButton', nowPlayingBar).show();
if (item.MediaStreams.filter(function (i) {
if (mediaStreams.filter(function (i) {
return i.Type == "Audio";
}).length) {
$('#audioTracksButton', nowPlayingBar).show();
@ -581,7 +584,7 @@
$('#audioTracksButton', nowPlayingBar).hide();
}
if (item.MediaStreams.filter(function (i) {
if (mediaStreams.filter(function (i) {
return i.Type == "Subtitle";
}).length) {
$('#subtitleButton', nowPlayingBar).show();
@ -589,7 +592,7 @@
$('#subtitleButton', nowPlayingBar).hide();
}
if (item.Chapters.length) {
if (item.Chapters && item.Chapters.length) {
$('#chaptersButton', nowPlayingBar).show();
} else {
$('#chaptersButton', nowPlayingBar).hide();
@ -1361,15 +1364,17 @@
var currentTicks = getCurrentTicks();
for (var i = 0, length = item.Chapters.length; i < length; i++) {
var chapters = item.Chapters || [];
var chapter = item.Chapters[i];
for (var i = 0, length = chapters.length; i < length; i++) {
var chapter = chapters[i];
var isSelected = false;
if (currentTicks >= chapter.StartPositionTicks) {
var nextChapter = item.Chapters[i + 1];
var nextChapter = chapters[i + 1];
isSelected = !nextChapter || currentTicks < nextChapter.StartPositionTicks;
}

View file

@ -9,7 +9,7 @@
SortBy: "DateCreated",
SortOrder: "Descending",
IncludeItemTypes: "Movie",
Limit: 7,
Limit: 6,
Recursive: true,
Fields: "PrimaryImageAspectRatio,DateCreated,UserData",
Filters: "IsUnplayed"
@ -32,7 +32,7 @@
SortOrder: "Descending",
IncludeItemTypes: "Movie",
Filters: "IsResumable",
Limit: 7,
Limit: 6,
Recursive: true,
Fields: "PrimaryImageAspectRatio,DateCreated,UserData"
};
@ -59,7 +59,7 @@
SortBy: "DateCreated",
SortOrder: "Descending",
IncludeItemTypes: "Trailer",
Limit: 7,
Limit: 6,
Recursive: true,
Fields: "PrimaryImageAspectRatio,DateCreated,UserData",
Filters: "IsUnplayed"

View file

@ -71,7 +71,7 @@
.jstree li {
margin-left: 10px;
min-width: 10px;
border-bottom: 1px solid #505050;
border-bottom: 1px solid #404040;
}
.jstree li:last-child {