live tv updates

This commit is contained in:
Luke Pulverenti 2015-04-11 21:38:38 -04:00
parent 16c69c903b
commit f41b336e87
15 changed files with 196 additions and 101 deletions

View File

@ -88,8 +88,8 @@
}*/
.ui-page-theme-b .visualCardBox {
background: rgb(51, 51, 51);
border: 1px solid rgb(31, 31, 31);
background: rgba(45,45,45,.85);
border: 1px solid #1f1f1f;
border-radius: 3px;
}
@ -365,10 +365,6 @@
@media all and (min-width: 1600px) {
.squareCard {
width: 12.5%;
}
.portraitCard {
width: 12.5%;
}
@ -386,7 +382,7 @@
@media all and (min-width: 1800px) {
.squareCard {
width: 10%;
width: 12.5%;
}
.portraitCard {
@ -398,8 +394,19 @@
}
}
@media all and (min-width: 1920px) {
.squareCard {
width: 11.111111111111111111111111111111%;
}
}
@media all and (min-width: 2200px) {
.squareCard {
width: 10%;
}
.backdropCard {
width: 16.666666666666666666666666666667%;
}

View File

@ -6,7 +6,7 @@
.tvProgram {
display: block;
text-decoration: none;
font-weight: normal!important;
font-weight: normal !important;
white-space: nowrap;
position: relative;
}
@ -173,13 +173,13 @@
}
.channelTimeslotHeader {
border-right: 1px solid #4971A7;
border-right: 1px solid #38c;
}
.channelTimeslotHeader, .timeslotHeader {
background: #4971A7;
border-bottom: 1px solid #4971A7;
border-left: 1px solid #4971A7;
background: #38c;
border-bottom: 1px solid #38c;
border-left: 1px solid #38c;
}
.timeslotHeader, .channelTimeslotHeader {
@ -190,8 +190,8 @@
padding: .5em .5em;
display: block;
text-decoration: none;
font-weight: normal!important;
color: #fff!important;
font-weight: normal !important;
color: #fff !important;
position: relative;
}
@ -228,8 +228,8 @@
top: 0;
display: block;
text-decoration: none;
font-weight: normal!important;
color: #fff!important;
font-weight: normal !important;
color: #fff !important;
}
.timeslotCellInnerWithProgram {
@ -278,60 +278,74 @@
@media (min-height: 500px) {
.channelList, .programGrid {
height: 290px;
height: 360px;
}
}
@media (min-height: 600px) {
.channelList, .programGrid {
height: 390px;
height: 400px;
}
}
@media (min-height: 700px) {
.channelList, .programGrid {
height: 490px;
height: 500px;
}
}
@media (min-height: 800px) {
.channelList, .programGrid {
height: 590px;
height: 600px;
}
}
@media (min-height: 900px) {
.channelList, .programGrid {
height: 690px;
height: 700px;
}
}
@media (min-height: 1000px) {
.channelList, .programGrid {
height: 790px;
height: 800px;
}
}
@media (min-height: 1100px) {
.channelList, .programGrid {
height: 890px;
height: 900px;
}
}
@media (min-height: 1200px) {
.channelList, .programGrid {
height: 950px;
height: 1000px;
}
}
@media (max-width: 600px) {
@media (min-height: 1300px) {
.channelList, .programGrid {
height: 1100px;
}
}
@media (min-height: 1400px) {
.channelList, .programGrid {
height: 1200px;
}
}
@media (max-width: 800px) {
.guideChannelImage {
display: none;
@ -340,4 +354,12 @@
.timerPageImageContainer {
display: none !important;
}
}
.channelHeaderCell, .channelTimeslotHeader {
width: 89px;
}
.programGrid, .timeslotHeaders {
margin-left: 90px;
}
}

View File

@ -13,15 +13,12 @@
<a href="livetvtimers.html">${TabScheduled}</a>
<a href="livetvseriestimers.html">${TabSeries}</a>
</div>
<div data-role="content" style="padding-top: 5px;">
<div data-role="content" style="padding-top: 5px;padding-left:0!important;padding-right:0!important;">
<div>
<div class="viewSettings">
<select id="selectDate" data-mini="true" data-icon="calendar" data-inline="true">
<select id="selectDate" data-mini="true" data-inline="true">
</select>
<div style="display: inline-block; vertical-align: middle;">
${HeaderChannels}
</div>
<div style="display: inline-block; vertical-align: middle;" class="channelPaging">
</div>
</div>

View File

@ -28,7 +28,7 @@
<div style="display: none;" id="eligibleForSeriesFields">
<p>
<input type="checkbox" data-mini="true" id="chkRecordSeries" />
<input type="checkbox" id="chkRecordSeries" />
<label for="chkRecordSeries">${OptionRecordSeries}</label>
</p>
<br />
@ -38,39 +38,39 @@
<h3>${HeaderDays}</h3>
<div data-role="controlgroup">
<input type="checkbox" data-mini="true" id="chkSunday" />
<input type="checkbox" id="chkSunday" />
<label for="chkSunday">${OptionSunday}</label>
<input type="checkbox" data-mini="true" id="chkMonday" />
<input type="checkbox" id="chkMonday" />
<label for="chkMonday">${OptionMonday}</label>
<input type="checkbox" data-mini="true" id="chkTuesday" />
<input type="checkbox" id="chkTuesday" />
<label for="chkTuesday">${OptionTuesday}</label>
<input type="checkbox" data-mini="true" id="chkWednesday" />
<input type="checkbox" id="chkWednesday" />
<label for="chkWednesday">${OptionWednesday}</label>
<input type="checkbox" data-mini="true" id="chkThursday" />
<input type="checkbox" id="chkThursday" />
<label for="chkThursday">${OptionThursday}</label>
<input type="checkbox" data-mini="true" id="chkFriday" />
<input type="checkbox" id="chkFriday" />
<label for="chkFriday">${OptionFriday}</label>
<input type="checkbox" data-mini="true" id="chkSaturday" />
<input type="checkbox" id="chkSaturday" />
<label for="chkSaturday">${OptionSaturday}</label>
</div>
</li>
<li>
<label for="chkNewOnly">${OptionRecordOnlyNewEpisodes}</label>
<input type="checkbox" id="chkNewOnly" data-mini="true" />
</li>
<li>
<label for="chkAnyTime">${OptionRecordAnytime}</label>
<input type="checkbox" id="chkAnyTime" data-mini="true" />
</li>
<li>
<label for="chkAllChannels">${OptionRecordOnAllChannels}</label>
<input type="checkbox" id="chkAllChannels" data-mini="true" />
<h3>${HeaderRepeatingOptions}</h3>
<div data-role="controlgroup">
<label for="chkNewOnly">${OptionRecordOnlyNewEpisodes}</label>
<input type="checkbox" id="chkNewOnly" />
<label for="chkAnyTime">${OptionRecordAnytime}</label>
<input type="checkbox" id="chkAnyTime" />
<label for="chkAllChannels">${OptionRecordOnAllChannels}</label>
<input type="checkbox" id="chkAllChannels" />
</div>
</li>
</ul>
</div>
@ -106,10 +106,10 @@
<br />
<ul data-role="listview" class="ulForm">
<li>
<button type="submit" data-theme="b" data-icon="check" data-mini="true">
<button type="submit" data-theme="a" data-icon="check">
${ButtonRecord}
</button>
<button id="btnCancel" type="button" data-icon="delete" data-mini="true">
<button id="btnCancel" type="button" data-icon="delete">
${ButtonCancel}
</button>
</li>

View File

@ -14,7 +14,7 @@
<a href="livetvseriestimers.html">${TabSeries}</a>
</div>
<div data-role="content">
<div class="viewSettings">
<div class="viewSettings" style="margin:.5em 0;">
<h1 class="listName" style="margin: 0 1em 0 0; display: inline-block; vertical-align: middle;"></h1>
@ -23,7 +23,7 @@
<div class="listTopPaging">
</div>
</div>
<div id="items" class="itemsContainer"></div>
<div id="items" class="itemsContainer" style="text-align:center;"></div>
</div>
</div>
</body>

View File

@ -17,12 +17,12 @@
<div class="ehsContent">
<div id="activeRecordings" style="display: none;">
<h1 class="listHeader">${HeaderActiveRecordings}</h1>
<div class="recordingItems"></div>
<div class="recordingItems itemsContainer"></div>
<br />
</div>
<div id="latestRecordings" style="display: none;">
<h1 class="listHeader">${HeaderLatestRecordings}</h1>
<div class="recordingItems"></div>
<div class="recordingItems itemsContainer"></div>
<br />
</div>
<div id="recordingGroups" style="display: none;">

View File

@ -37,39 +37,39 @@
<h3>${HeaderDays}</h3>
<div data-role="controlgroup">
<input type="checkbox" data-mini="true" id="chkSunday" />
<input type="checkbox" id="chkSunday" />
<label for="chkSunday">${OptionSunday}</label>
<input type="checkbox" data-mini="true" id="chkMonday" />
<input type="checkbox" id="chkMonday" />
<label for="chkMonday">${OptionMonday}</label>
<input type="checkbox" data-mini="true" id="chkTuesday" />
<input type="checkbox" id="chkTuesday" />
<label for="chkTuesday">${OptionTuesday}</label>
<input type="checkbox" data-mini="true" id="chkWednesday" />
<input type="checkbox" id="chkWednesday" />
<label for="chkWednesday">${OptionWednesday}</label>
<input type="checkbox" data-mini="true" id="chkThursday" />
<input type="checkbox" id="chkThursday" />
<label for="chkThursday">${OptionThursday}</label>
<input type="checkbox" data-mini="true" id="chkFriday" />
<input type="checkbox" id="chkFriday" />
<label for="chkFriday">${OptionFriday}</label>
<input type="checkbox" data-mini="true" id="chkSaturday" />
<input type="checkbox" id="chkSaturday" />
<label for="chkSaturday">${OptionSaturday}</label>
</div>
</li>
<li>
<label for="chkNewOnly">${OptionRecordOnlyNewEpisodes}</label>
<input type="checkbox" id="chkNewOnly" data-mini="true" />
</li>
<li>
<label for="chkAnyTime">${OptionRecordAnytime}</label>
<input type="checkbox" id="chkAnyTime" data-mini="true" />
</li>
<li>
<label for="chkAllChannels">${OptionRecordOnAllChannels}</label>
<input type="checkbox" id="chkAllChannels" data-mini="true" />
<h3>${HeaderRepeatingOptions}</h3>
<div data-role="controlgroup">
<label for="chkNewOnly">${OptionRecordOnlyNewEpisodes}</label>
<input type="checkbox" id="chkNewOnly" />
<label for="chkAnyTime">${OptionRecordAnytime}</label>
<input type="checkbox" id="chkAnyTime" />
<label for="chkAllChannels">${OptionRecordOnAllChannels}</label>
<input type="checkbox" id="chkAllChannels" />
</div>
</li>
</ul>
<div data-role="collapsible" data-mini="true">
@ -101,10 +101,10 @@
</div>
<br />
<div>
<button type="submit" data-theme="a" data-icon="check" data-mini="true">
<button type="submit" data-theme="a" data-icon="check">
${ButtonSave}
</button>
<button type="button" onclick="history.back();" data-icon="delete" data-mini="true">
<button type="button" onclick="history.back();" data-icon="delete">
${ButtonCancel}
</button>
</div>

View File

@ -24,6 +24,13 @@
</div>
</div>
<div id="playlists" style="display: none;" class="homePageSection">
<h1 class="listHeader">${HeaderPlaylists}</h1>
<div class="itemsContainer fullWidthItemsContainer" style="text-align:left;">
</div>
</div>
<div id="recentlyPlayed" style="display: none;" class="homePageSection">
<h1 class="listHeader">${HeaderRecentlyPlayed}</h1>

View File

@ -2,7 +2,8 @@
var query = {
StartIndex: 0
StartIndex: 0,
EnableFavoriteSorting: true
};
function getChannelsHtml(channels) {

View File

@ -12,7 +12,8 @@
var channelQuery = {
StartIndex: 0,
Limit: 20
Limit: 20,
EnableFavoriteSorting: true
};
var channelsPromise;

View File

@ -1,6 +1,6 @@
(function ($, document) {
var view = LibraryBrowser.getDefaultItemsView('PosterCard', 'PosterCard');
var view = LibraryBrowser.getDefaultItemsView('Poster', 'Poster');
var currentDate = new Date();
currentDate.setHours(0, 0, 0, 0);
@ -14,7 +14,7 @@
};
function getSavedQueryKey() {
return 'livetvitems' + (query.ParentId || '');
return 'livetvitems2' + (query.ParentId || '');
}
function updateFilterControls(page) {
@ -72,8 +72,6 @@
});
}
$('.itemsContainer', page).html(html).lazyChildren();
var elem = $('.itemsContainer', page).html(html).lazyChildren();
$(pagingHtml).appendTo(elem).trigger('create');

View File

@ -58,9 +58,10 @@
showTitle: true,
showParentTitle: true,
overlayText: screenWidth >= 600,
coverImage: true
coverImage: true,
lazy: true
}));
})).lazyChildren();
}
function reload(page) {

View File

@ -8,7 +8,7 @@
userId: Dashboard.getCurrentUserId(),
IsAiring: true,
limit: 16
limit: 18
}).done(function (result) {
@ -32,7 +32,7 @@
userId: Dashboard.getCurrentUserId(),
IsAiring: false,
HasAired: false,
limit: 10,
limit: 9,
IsMovie: false,
IsSports: false
@ -58,7 +58,7 @@
userId: Dashboard.getCurrentUserId(),
IsAiring: false,
HasAired: false,
limit: 10,
limit: 9,
IsMovie: true
}).done(function (result) {
@ -66,7 +66,7 @@
var html = LibraryBrowser.getPosterViewHtml({
items: result.Items,
shape: "auto",
showTitle: true,
showTitle: false,
coverImage: true,
overlayText: false,
lazy: true
@ -80,7 +80,7 @@
userId: Dashboard.getCurrentUserId(),
IsAiring: false,
HasAired: false,
limit: 10,
limit: 9,
IsSports: true
}).done(function (result) {
@ -88,7 +88,7 @@
var html = LibraryBrowser.getPosterViewHtml({
items: result.Items,
shape: "auto",
showTitle: true,
showTitle: false,
coverImage: true,
overlayText: false,
lazy: true

View File

@ -1,16 +1,12 @@
(function ($, document) {
$(document).on('pagebeforeshow', "#musicRecommendedPage", function () {
function loadLatest(page, parentId) {
var userId = Dashboard.getCurrentUserId();
var page = this;
var parentId = LibraryMenu.getTopParentId();
var options = {
IncludeItemTypes: "Audio",
Limit: 20,
Limit: 9,
Fields: "PrimaryImageAspectRatio,SyncInfo",
ParentId: parentId,
ImageTypeLimit: 1,
@ -26,17 +22,22 @@
shape: "square",
showTitle: true,
showParentTitle: true,
lazy: true
lazy: true,
cardLayout: true
})).lazyChildren();
});
}
options = {
function loadRecentlyPlayed(page, parentId) {
var options = {
SortBy: "DatePlayed",
SortOrder: "Descending",
IncludeItemTypes: "Audio",
Limit: 10,
Limit: 9,
Recursive: true,
Fields: "PrimaryImageAspectRatio,AudioInfo,SyncInfo",
Filters: "IsPlayed",
@ -60,18 +61,23 @@
showTitle: true,
showParentTitle: true,
defaultAction: 'play',
lazy: true
lazy: true,
cardLayout: true
})).lazyChildren();
});
options = {
}
function loadFrequentlyPlayed(page, parentId) {
var options = {
SortBy: "PlayCount",
SortOrder: "Descending",
IncludeItemTypes: "Audio",
Limit: 20,
Limit: 9,
Recursive: true,
Fields: "PrimaryImageAspectRatio,AudioInfo,SyncInfo",
Filters: "IsPlayed",
@ -95,12 +101,64 @@
showTitle: true,
showParentTitle: true,
defaultAction: 'play',
lazy: true
lazy: true,
cardLayout: true
})).lazyChildren();
});
}
function loadPlaylists(page, parentId) {
var options = {
SortBy: "SortName",
SortOrder: "Ascending",
IncludeItemTypes: "Playlist",
Recursive: true,
ParentId: parentId,
Fields: "PrimaryImageAspectRatio,SortName,CumulativeRunTimeTicks,CanDelete,SyncInfo",
StartIndex: 0,
Limit: 9
};
ApiClient.getItems(Dashboard.getCurrentUserId(), options).done(function (result) {
var elem;
if (result.Items.length) {
elem = $('#playlists', page).show();
} else {
elem = $('#playlists', page).hide();
}
$('.itemsContainer', elem).html(LibraryBrowser.getPosterViewHtml({
items: result.Items,
shape: "square",
showTitle: true,
lazy: true,
coverImage: true,
showItemCounts: true,
cardLayout: true
})).lazyChildren();
});
}
$(document).on('pagebeforeshow', "#musicRecommendedPage", function () {
var parentId = LibraryMenu.getTopParentId();
var page = this;
loadLatest(page, parentId);
loadPlaylists(page, parentId);
loadRecentlyPlayed(page, parentId);
loadFrequentlyPlayed(page, parentId);
});

View File

@ -212,6 +212,9 @@
supportsPlaylists: function (item) {
if (item.Type == 'Program') {
return false;
}
return item.RunTimeTicks || item.IsFolder || item.Type == "Genre" || item.Type == "MusicGenre" || item.Type == "MusicArtist";
}
};