mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
added ps4 profile
This commit is contained in:
parent
0d59297b1b
commit
10d2fbe3b3
43 changed files with 1245 additions and 267 deletions
|
@ -197,7 +197,7 @@
|
|||
}
|
||||
}
|
||||
|
||||
$(document).on('pageshowready', ".page", function () {
|
||||
$(document).on('pagebeforeshowready', ".page", function () {
|
||||
|
||||
var page = this;
|
||||
|
||||
|
@ -212,10 +212,7 @@
|
|||
|
||||
var parentId = $page.hasClass('globalBackdropPage') ? '' : LibraryMenu.getTopParentId();
|
||||
|
||||
// This is an artificial timeout, but we want to give priority to the regular data requests for the page
|
||||
setTimeout(function () {
|
||||
showBackdrop(type, parentId);
|
||||
}, 100);
|
||||
showBackdrop(type, parentId);
|
||||
|
||||
} else {
|
||||
$page.removeClass('backdropPage');
|
||||
|
|
|
@ -28,7 +28,7 @@
|
|||
Sections.loadLatestChannelItems($(".section2", page), userId);
|
||||
}
|
||||
|
||||
$(document).on('pageshowready', "#homeLatestPage", function () {
|
||||
$(document).on('pagebeforeshowready', "#homeLatestPage", function () {
|
||||
|
||||
var page = this;
|
||||
|
||||
|
|
|
@ -1090,7 +1090,7 @@
|
|||
}
|
||||
|
||||
if (limit && result.TotalRecordCount > limit) {
|
||||
html += '<p style="margin: 0;padding-left: .5em;"><button class="moreCriticReviews" data-inline="true" data-mini="true">' + Globalize.translate('ButtonMoreItems') + '</button></p>';
|
||||
html += '<p style="margin: 0;"><paper-button raised class="more mini moreCriticReviews">' + Globalize.translate('ButtonMoreItems') + '</paper-button></p>';
|
||||
}
|
||||
|
||||
$('#criticReviewsContent', page).html(html).trigger('create');
|
||||
|
@ -1248,7 +1248,7 @@
|
|||
}
|
||||
|
||||
if (limit && chapters.length > limit) {
|
||||
html += '<p style="margin: 0;padding-left: .5em;"><button class="moreScenes" data-inline="true" data-mini="true">' + Globalize.translate('ButtonMoreItems') + '</button></p>';
|
||||
html += '<p style="margin: 0;"><paper-button raised class="more mini moreScenes">' + Globalize.translate('ButtonMoreItems') + '</paper-button></p>';
|
||||
}
|
||||
|
||||
$('#scenesContent', page).html(html).trigger('create').lazyChildren();
|
||||
|
@ -1480,7 +1480,7 @@
|
|||
}
|
||||
|
||||
if (limit && items.length > limit) {
|
||||
html += '<p style="margin: 0;padding-left: .5em;"><button class="' + moreButtonClass + '" data-inline="true" data-mini="true">' + Globalize.translate('ButtonMoreItems') + '</button></p>';
|
||||
html += '<p style="margin: 0;"><paper-button raised class="more mini ' + moreButtonClass + '">' + Globalize.translate('ButtonMoreItems') + '</paper-button></p>';
|
||||
}
|
||||
|
||||
return html;
|
||||
|
@ -1557,7 +1557,7 @@
|
|||
}
|
||||
|
||||
if (limit && casts.length > limit) {
|
||||
html += '<p style="margin: 0;padding-left: .5em;"><button class="morePeople" data-inline="true" data-mini="true">' + Globalize.translate('ButtonMoreItems') + '</button></p>';
|
||||
html += '<p style="margin: 0;"><paper-button raised class="more mini morePeople">' + Globalize.translate('ButtonMoreItems') + '</paper-button></p>';
|
||||
}
|
||||
|
||||
$('#castContent', page).html(html).lazyChildren().trigger('create');
|
||||
|
|
|
@ -41,6 +41,7 @@
|
|||
|
||||
if (!$.browser.mobile && !AppInfo.isNativeApp) {
|
||||
html += '<a href="dashboard.html" class="headerButton headerButtonRight dashboardEntryHeaderButton" style="display:none;"><i class="material-icons">settings</i></a>';
|
||||
//html += '<a href="dashboard.html" class="headerButton headerButtonRight dashboardEntryHeaderButton clearLink" style="display:none;"><paper-icon-button icon="settings"></paper-icon-button></a>';
|
||||
}
|
||||
|
||||
html += '</div>';
|
||||
|
|
|
@ -18,11 +18,11 @@
|
|||
|
||||
function showLoadingMessage(page) {
|
||||
|
||||
$('.popupLoading', page).popup('open');
|
||||
Dashboard.showLoadingMsg();
|
||||
}
|
||||
|
||||
function hideLoadingMessage(page) {
|
||||
$('.popupLoading', page).popup('close');
|
||||
Dashboard.hideLoadingMsg();
|
||||
}
|
||||
|
||||
function renderChannels(page, result) {
|
||||
|
|
|
@ -21,11 +21,11 @@
|
|||
|
||||
function showLoadingMessage(page) {
|
||||
|
||||
$('.popupLoading', page).popup('open');
|
||||
Dashboard.showModalLoadingMsg();
|
||||
}
|
||||
|
||||
function hideLoadingMessage(page) {
|
||||
$('.popupLoading', page).popup('close');
|
||||
Dashboard.hideModalLoadingMsg();
|
||||
}
|
||||
|
||||
function normalizeDateToTimeslot(date) {
|
||||
|
|
|
@ -20,11 +20,11 @@
|
|||
|
||||
function showLoadingMessage(page) {
|
||||
|
||||
$('.popupLoading', page).popup('open');
|
||||
Dashboard.showLoadingMsg();
|
||||
}
|
||||
|
||||
function hideLoadingMessage(page) {
|
||||
$('.popupLoading', page).popup('close');
|
||||
Dashboard.hideLoadingMsg();
|
||||
}
|
||||
|
||||
function reloadItems(page) {
|
||||
|
|
|
@ -154,7 +154,7 @@
|
|||
html += '<h1 style="display:inline-block; vertical-align:middle;" class="listHeader">' + Globalize.translate('HeaderLatestMedia') + '</h1>';
|
||||
|
||||
if (user.Policy.EnableUserPreferenceAccess && !AppInfo.isNativeApp) {
|
||||
html += '<a href="mypreferencesdisplay.html" class="clearLink" style="margin-left:2em;"><paper-button raised class="secondary mini"><i class="fa fa-pencil"></i>' + Globalize.translate('ButtonEdit') + '</paper-button></a>';
|
||||
html += '<a href="mypreferencesdisplay.html" class="clearLink" style="margin-left:2em;"><paper-button raised class="submit mini"><i class="fa fa-pencil"></i>' + Globalize.translate('ButtonEdit') + '</paper-button></a>';
|
||||
}
|
||||
|
||||
html += '</div>';
|
||||
|
@ -236,7 +236,7 @@
|
|||
html += '<h1 style="display:inline-block; vertical-align:middle;" class="' + cssClass + '">' + Globalize.translate('HeaderMyMedia') + '</h1>';
|
||||
|
||||
if (user.Policy.EnableUserPreferenceAccess && !AppInfo.isNativeApp) {
|
||||
html += '<a href="mypreferencesdisplay.html" class="clearLink" style="margin-left:2em;"><paper-button raised class="secondary mini"><i class="fa fa-pencil"></i>' + Globalize.translate('ButtonEdit') + '</paper-button></a>';
|
||||
html += '<a href="mypreferencesdisplay.html" class="clearLink" style="margin-left:2em;"><paper-button raised class="submit mini"><i class="fa fa-pencil"></i>' + Globalize.translate('ButtonEdit') + '</paper-button></a>';
|
||||
}
|
||||
|
||||
html += '</div>';
|
||||
|
@ -387,7 +387,7 @@
|
|||
html += '<div>';
|
||||
var text = Globalize.translate('HeaderLatestFromChannel').replace('{0}', channel.Name);
|
||||
html += '<h1 style="display:inline-block; vertical-align:middle;" class="' + cssClass + '">' + text + '</h1>';
|
||||
html += '<a href="channelitems.html?context=channels&id=' + channel.Id + '" data-role="button" data-icon="arrow-r" data-mini="true" data-inline="true" data-iconpos="notext" class="sectionHeaderButton"></a>';
|
||||
html += '<a href="channelitems.html?context=channels&id=' + channel.Id + '" class="clearLink" style="margin-left:2em;"><paper-button raised class="more mini"><span>' + Globalize.translate('ButtonMore') + '</span></paper-button></a>';
|
||||
html += '</div>';
|
||||
}
|
||||
html += '<div class="itemsContainer">';
|
||||
|
@ -425,7 +425,7 @@
|
|||
|
||||
html += '<div>';
|
||||
html += '<h1 style="display:inline-block; vertical-align:middle;" class="' + cssClass + '">' + Globalize.translate('HeaderLatestTvRecordings') + '</h1>';
|
||||
html += '<a href="livetvrecordings.html?context=livetv" data-role="button" data-icon="arrow-r" data-mini="true" data-inline="true" data-iconpos="notext" class="sectionHeaderButton"></a>';
|
||||
html += '<a href="livetvrecordings.html?context=livetv" class="clearLink" style="margin-left:2em;"><paper-button raised class="more mini"><span>' + Globalize.translate('ButtonMore') + '</span></paper-button></a>';
|
||||
html += '</div>';
|
||||
}
|
||||
|
||||
|
|
|
@ -51,6 +51,12 @@ var Dashboard = {
|
|||
$.event.special.swipe.verticalDistanceThreshold = 40;
|
||||
$.mobile.loader.prototype.options.disabled = true;
|
||||
//$.mobile.page.prototype.options.domCache = true;
|
||||
|
||||
$.mobile.loadingMessage = false;
|
||||
$.mobile.loader.prototype.options.html = "";
|
||||
$.mobile.loader.prototype.options.textVisible = false;
|
||||
$.mobile.loader.prototype.options.textOnly = true;
|
||||
$.mobile.loader.prototype.options.text = "";
|
||||
},
|
||||
|
||||
isConnectMode: function () {
|
||||
|
@ -218,15 +224,7 @@ var Dashboard = {
|
|||
|
||||
showError: function (message) {
|
||||
|
||||
$.mobile.loading('show', {
|
||||
text: message,
|
||||
textonly: true,
|
||||
textVisible: true
|
||||
});
|
||||
|
||||
setTimeout(function () {
|
||||
$.mobile.loading('hide');
|
||||
}, 3000);
|
||||
Dashboard.alert(message);
|
||||
},
|
||||
|
||||
updateSystemInfo: function (info) {
|
||||
|
@ -442,11 +440,38 @@ var Dashboard = {
|
|||
},
|
||||
|
||||
showLoadingMsg: function () {
|
||||
$.mobile.loading("show");
|
||||
|
||||
require(['paperbuttonstyle'], function () {
|
||||
var elem = document.getElementById('docspinner');
|
||||
|
||||
if (elem) {
|
||||
|
||||
// This is just an attempt to prevent the fade-in animation from running repeating and causing flickering
|
||||
if (!elem.active) {
|
||||
elem.active = true;
|
||||
}
|
||||
|
||||
} else {
|
||||
elem = document.createElement("paper-spinner");
|
||||
elem.id = 'docspinner';
|
||||
|
||||
document.body.appendChild(elem);
|
||||
|
||||
elem.active = true;
|
||||
}
|
||||
});
|
||||
},
|
||||
|
||||
hideLoadingMsg: function () {
|
||||
$.mobile.loading("hide");
|
||||
|
||||
var elem = document.getElementById('docspinner');
|
||||
|
||||
if (elem) {
|
||||
|
||||
setTimeout(function () {
|
||||
elem.active = false;
|
||||
}, 500);
|
||||
}
|
||||
},
|
||||
|
||||
getModalLoadingMsg: function () {
|
||||
|
@ -492,18 +517,30 @@ var Dashboard = {
|
|||
|
||||
if (typeof options == "string") {
|
||||
|
||||
var message = options;
|
||||
require(['paperbuttonstyle'], function () {
|
||||
var message = options;
|
||||
|
||||
$.mobile.loading('show', {
|
||||
text: message,
|
||||
textonly: true,
|
||||
textVisible: true
|
||||
Dashboard.toastId = Dashboard.toastId || 0;
|
||||
|
||||
var id = 'toast' + (Dashboard.toastId++);
|
||||
|
||||
var elem = document.createElement("paper-toast");
|
||||
elem.setAttribute('text', message);
|
||||
elem.id = id;
|
||||
|
||||
document.body.appendChild(elem);
|
||||
|
||||
// This timeout is obviously messy but it's unclear how to determine when the webcomponent is ready for use
|
||||
// element onload never fires
|
||||
setTimeout(function () {
|
||||
elem.show();
|
||||
|
||||
setTimeout(function () {
|
||||
elem.parentNode.removeChild(elem);
|
||||
}, 5000);
|
||||
}, 300);
|
||||
});
|
||||
|
||||
setTimeout(function () {
|
||||
$.mobile.loading('hide');
|
||||
}, 3000);
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -1270,7 +1307,7 @@ var Dashboard = {
|
|||
html += '<h1 class="pageTitle" style="display:inline-block;">' + (document.title || ' ') + '</h1>';
|
||||
|
||||
if (helpUrl) {
|
||||
html += '<a href="' + helpUrl + '" target="_blank" class="clearLink" style="margin-top:-10px;display:inline-block;vertical-align:middle;margin-left:1em;"><paper-button raised class="secondary mini"><i class="fa fa-info-circle"></i>'+Globalize.translate('ButtonHelp')+'</paper-button></a>';
|
||||
html += '<a href="' + helpUrl + '" target="_blank" class="clearLink" style="margin-top:-10px;display:inline-block;vertical-align:middle;margin-left:1em;"><paper-button raised class="secondary mini"><i class="fa fa-info-circle"></i>' + Globalize.translate('ButtonHelp') + '</paper-button></a>';
|
||||
}
|
||||
|
||||
html += '</div>';
|
||||
|
@ -1278,7 +1315,7 @@ var Dashboard = {
|
|||
$(parent).prepend(html);
|
||||
|
||||
if (helpUrl) {
|
||||
require(['css!thirdparty/paper-button/paper-button-style']);
|
||||
require(['paperbuttonstyle']);
|
||||
}
|
||||
},
|
||||
|
||||
|
@ -1615,7 +1652,7 @@ var AppInfo = {};
|
|||
else {
|
||||
|
||||
if (!$.browser.tv) {
|
||||
//AppInfo.enableHeadRoom = true;
|
||||
AppInfo.enableHeadRoom = true;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1715,7 +1752,7 @@ var AppInfo = {};
|
|||
|
||||
function initFastClick() {
|
||||
|
||||
requirejs(["thirdparty/fastclick"], function (FastClick) {
|
||||
require(["thirdparty/fastclick"], function (FastClick) {
|
||||
|
||||
FastClick.attach(document.body);
|
||||
|
||||
|
@ -1892,19 +1929,19 @@ var AppInfo = {};
|
|||
require(['filesystem']);
|
||||
|
||||
if (Dashboard.isRunningInCordova()) {
|
||||
requirejs(['thirdparty/cordova/connectsdk', 'scripts/registrationservices', 'thirdparty/cordova/volume', 'thirdparty/cordova/back']);
|
||||
require(['thirdparty/cordova/connectsdk', 'scripts/registrationservices', 'thirdparty/cordova/volume', 'thirdparty/cordova/back']);
|
||||
|
||||
if ($.browser.android) {
|
||||
requirejs(['thirdparty/cordova/android/androidcredentials', 'thirdparty/cordova/android/immersive', 'thirdparty/cordova/android/mediasession']);
|
||||
require(['thirdparty/cordova/android/androidcredentials', 'thirdparty/cordova/android/immersive', 'thirdparty/cordova/android/mediasession']);
|
||||
}
|
||||
|
||||
if ($.browser.safari) {
|
||||
requirejs(['thirdparty/cordova/remotecontrols', 'thirdparty/cordova/ios/orientation']);
|
||||
require(['thirdparty/cordova/remotecontrols', 'thirdparty/cordova/ios/orientation']);
|
||||
}
|
||||
|
||||
} else {
|
||||
if ($.browser.chrome) {
|
||||
requirejs(['scripts/chromecast']);
|
||||
require(['scripts/chromecast']);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -1975,6 +2012,7 @@ var AppInfo = {};
|
|||
}
|
||||
|
||||
define("connectservice", ["thirdparty/apiclient/connectservice"]);
|
||||
define("paperbuttonstyle", ["css!thirdparty/paper-button/paper-button-style"]);
|
||||
|
||||
//requirejs(['http://viblast.com/player/free-version/qy2fdwajo1/viblast.js']);
|
||||
|
||||
|
@ -1991,35 +2029,36 @@ var AppInfo = {};
|
|||
$(document.body).addClass('bottomSecondaryNav');
|
||||
}
|
||||
|
||||
if (Dashboard.isConnectMode()) {
|
||||
$(document).on('WebComponentsReady', function () {
|
||||
if (Dashboard.isConnectMode()) {
|
||||
|
||||
require(['appstorage'], function () {
|
||||
require(['appstorage'], function () {
|
||||
|
||||
capabilities.DeviceProfile = MediaPlayer.getDeviceProfile(Math.max(screen.height, screen.width));
|
||||
createConnectionManager(capabilities).done(function () {
|
||||
$(function () {
|
||||
onDocumentReady();
|
||||
Dashboard.initPromiseDone = true;
|
||||
deferred.resolve();
|
||||
capabilities.DeviceProfile = MediaPlayer.getDeviceProfile(Math.max(screen.height, screen.width));
|
||||
createConnectionManager(capabilities).done(function () {
|
||||
$(function () {
|
||||
onDocumentReady();
|
||||
Dashboard.initPromiseDone = true;
|
||||
deferred.resolve();
|
||||
});
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
} else {
|
||||
createConnectionManager(capabilities);
|
||||
} else {
|
||||
createConnectionManager(capabilities);
|
||||
|
||||
|
||||
$(function() {
|
||||
onDocumentReady();
|
||||
Dashboard.initPromiseDone = true;
|
||||
deferred.resolve();
|
||||
});
|
||||
}
|
||||
$(function () {
|
||||
onDocumentReady();
|
||||
});
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function initCordovaWithDeviceId(deferred, deviceId) {
|
||||
|
||||
requirejs(['thirdparty/cordova/imagestore.js']);
|
||||
require(['thirdparty/cordova/imagestore']);
|
||||
|
||||
var capablities = Dashboard.capabilities();
|
||||
|
||||
|
@ -2089,10 +2128,10 @@ $(document).on('pagecreate', ".page", function () {
|
|||
|
||||
var page = this;
|
||||
|
||||
var require = this.getAttribute('data-require');
|
||||
var dependencies = this.getAttribute('data-require');
|
||||
|
||||
if (require) {
|
||||
requirejs(require.split(','), function () {
|
||||
if (dependencies) {
|
||||
require(dependencies.split(','), function () {
|
||||
|
||||
Dashboard.firePageEvent(page, 'pageinitdepends');
|
||||
});
|
||||
|
@ -2105,12 +2144,12 @@ $(document).on('pagecreate', ".page", function () {
|
|||
}).on('pagebeforeshow', ".page", function () {
|
||||
|
||||
var page = this;
|
||||
var require = this.getAttribute('data-require');
|
||||
var dependencies = this.getAttribute('data-require');
|
||||
|
||||
Dashboard.ensurePageTitle($(page));
|
||||
|
||||
if (require) {
|
||||
requirejs(require.split(','), function () {
|
||||
if (dependencies) {
|
||||
require(dependencies.split(','), function () {
|
||||
|
||||
Dashboard.firePageEvent(page, 'pagebeforeshowready');
|
||||
});
|
||||
|
@ -2121,10 +2160,10 @@ $(document).on('pagecreate', ".page", function () {
|
|||
}).on('pageshow', ".page", function () {
|
||||
|
||||
var page = this;
|
||||
var require = this.getAttribute('data-require');
|
||||
var dependencies = this.getAttribute('data-require');
|
||||
|
||||
if (require) {
|
||||
requirejs(require.split(','), function () {
|
||||
if (dependencies) {
|
||||
require(dependencies.split(','), function () {
|
||||
|
||||
Dashboard.firePageEvent(page, 'pageshowbeginready');
|
||||
});
|
||||
|
|
|
@ -240,7 +240,7 @@
|
|||
html += '</div>';
|
||||
|
||||
$(document.body).append(html);
|
||||
require(['css!thirdparty/paper-button/paper-button-style']);
|
||||
require(['paperbuttonstyle']);
|
||||
|
||||
var elem = $('.syncPanel').panel({}).trigger('create').panel("open").on("panelclose", function () {
|
||||
$(this).off("panelclose").remove();
|
||||
|
|
|
@ -179,7 +179,7 @@
|
|||
});
|
||||
}
|
||||
|
||||
$(document).on('pageshowready', "#tvRecommendedPage", function () {
|
||||
$(document).on('pagebeforeshowready', "#tvRecommendedPage", function () {
|
||||
|
||||
var page = this;
|
||||
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
$('.globalNav', page).show();
|
||||
}
|
||||
|
||||
}).on('pageshowready', "#tvUpcomingPage", function () {
|
||||
}).on('pagebeforeshowready', "#tvUpcomingPage", function () {
|
||||
|
||||
var page = this;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue