mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
update startup
This commit is contained in:
parent
265c46566d
commit
417651cbdc
1 changed files with 14 additions and 6 deletions
|
@ -1680,6 +1680,7 @@ var AppInfo = {};
|
||||||
window.ConnectionManager.clearData();
|
window.ConnectionManager.clearData();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
console.log('binding to apiclientcreated');
|
||||||
Events.on(ConnectionManager, 'apiclientcreated', onApiClientCreated);
|
Events.on(ConnectionManager, 'apiclientcreated', onApiClientCreated);
|
||||||
|
|
||||||
if (Dashboard.isConnectMode()) {
|
if (Dashboard.isConnectMode()) {
|
||||||
|
@ -1702,12 +1703,19 @@ var AppInfo = {};
|
||||||
}
|
}
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
|
console.log('loading ApiClient singleton');
|
||||||
|
|
||||||
return getRequirePromise(['apiclient']).then(function (apiClientFactory) {
|
return getRequirePromise(['apiclient']).then(function (apiClientFactory) {
|
||||||
|
|
||||||
|
console.log('creating ApiClient singleton');
|
||||||
|
|
||||||
var apiClient = new apiClientFactory(Dashboard.serverAddress(), AppInfo.appName, AppInfo.appVersion, AppInfo.deviceName, AppInfo.deviceId, window.devicePixelRatio);
|
var apiClient = new apiClientFactory(Dashboard.serverAddress(), AppInfo.appName, AppInfo.appVersion, AppInfo.deviceName, AppInfo.deviceId, window.devicePixelRatio);
|
||||||
apiClient.enableAutomaticNetworking = false;
|
apiClient.enableAutomaticNetworking = false;
|
||||||
ConnectionManager.addApiClient(apiClient);
|
ConnectionManager.addApiClient(apiClient);
|
||||||
Dashboard.importCss(apiClient.getUrl('Branding/Css'));
|
Dashboard.importCss(apiClient.getUrl('Branding/Css'));
|
||||||
window.ApiClient = apiClient;
|
window.ApiClient = apiClient;
|
||||||
|
console.log('loaded ApiClient singleton');
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -1846,7 +1854,8 @@ var AppInfo = {};
|
||||||
browserdeviceprofile: embyWebComponentsBowerPath + "/browserdeviceprofile",
|
browserdeviceprofile: embyWebComponentsBowerPath + "/browserdeviceprofile",
|
||||||
browser: embyWebComponentsBowerPath + "/browser",
|
browser: embyWebComponentsBowerPath + "/browser",
|
||||||
qualityoptions: embyWebComponentsBowerPath + "/qualityoptions",
|
qualityoptions: embyWebComponentsBowerPath + "/qualityoptions",
|
||||||
connectservice: apiClientBowerPath + '/connectservice'
|
connectservice: apiClientBowerPath + '/connectservice',
|
||||||
|
hammer: bowerPath + "/hammerjs/hammer.min"
|
||||||
};
|
};
|
||||||
|
|
||||||
if (navigator.webkitPersistentStorage) {
|
if (navigator.webkitPersistentStorage) {
|
||||||
|
@ -1957,10 +1966,6 @@ var AppInfo = {};
|
||||||
|
|
||||||
define("jqmpanel", ["thirdparty/jquerymobile-1.4.5/jqm.panel", 'css!thirdparty/jquerymobile-1.4.5/jqm.panel.css']);
|
define("jqmpanel", ["thirdparty/jquerymobile-1.4.5/jqm.panel", 'css!thirdparty/jquerymobile-1.4.5/jqm.panel.css']);
|
||||||
|
|
||||||
define("hammer", [bowerPath + "/hammerjs/hammer.min"], function (Hammer) {
|
|
||||||
return Hammer;
|
|
||||||
});
|
|
||||||
|
|
||||||
define("swipebox", [bowerPath + '/swipebox/src/js/jquery.swipebox.min', "css!" + bowerPath + "/swipebox/src/css/swipebox.min.css"]);
|
define("swipebox", [bowerPath + '/swipebox/src/js/jquery.swipebox.min', "css!" + bowerPath + "/swipebox/src/css/swipebox.min.css"]);
|
||||||
|
|
||||||
define('fetch', [bowerPath + '/fetch/fetch']);
|
define('fetch', [bowerPath + '/fetch/fetch']);
|
||||||
|
@ -2148,7 +2153,6 @@ var AppInfo = {};
|
||||||
deps.push('paper-icon-button');
|
deps.push('paper-icon-button');
|
||||||
deps.push('paper-button');
|
deps.push('paper-button');
|
||||||
deps.push('thirdparty/jquerymobile-1.4.5/jquery.mobile.custom.js');
|
deps.push('thirdparty/jquerymobile-1.4.5/jquery.mobile.custom.js');
|
||||||
deps.push('scripts/librarybrowser');
|
|
||||||
promises.push(getRequirePromise(deps));
|
promises.push(getRequirePromise(deps));
|
||||||
|
|
||||||
promises.push(Globalize.ensure());
|
promises.push(Globalize.ensure());
|
||||||
|
@ -2156,6 +2160,7 @@ var AppInfo = {};
|
||||||
|
|
||||||
Promise.all(promises).then(function () {
|
Promise.all(promises).then(function () {
|
||||||
|
|
||||||
|
console.log('initAfterDependencies promises resolved');
|
||||||
MediaController.init();
|
MediaController.init();
|
||||||
|
|
||||||
document.title = Globalize.translateDocument(document.title, 'html');
|
document.title = Globalize.translateDocument(document.title, 'html');
|
||||||
|
@ -2206,6 +2211,8 @@ var AppInfo = {};
|
||||||
|
|
||||||
function onAppReady() {
|
function onAppReady() {
|
||||||
|
|
||||||
|
console.log('Begin onAppReady');
|
||||||
|
|
||||||
var deps = [];
|
var deps = [];
|
||||||
|
|
||||||
if (!(AppInfo.isNativeApp && browserInfo.android)) {
|
if (!(AppInfo.isNativeApp && browserInfo.android)) {
|
||||||
|
@ -2248,6 +2255,7 @@ var AppInfo = {};
|
||||||
deps.push('scripts/sync');
|
deps.push('scripts/sync');
|
||||||
deps.push('scripts/backdrops');
|
deps.push('scripts/backdrops');
|
||||||
deps.push('scripts/librarymenu');
|
deps.push('scripts/librarymenu');
|
||||||
|
deps.push('scripts/librarybrowser');
|
||||||
|
|
||||||
deps.push('css!css/card.css');
|
deps.push('css!css/card.css');
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue