mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
lazy load chromecast script
This commit is contained in:
parent
3114742ab7
commit
4b6692c92d
2 changed files with 11 additions and 2 deletions
|
@ -1488,8 +1488,8 @@ var Dashboard = {
|
||||||
return deferred.promise();
|
return deferred.promise();
|
||||||
},
|
},
|
||||||
|
|
||||||
onLoggedIn: function(serverAddress, userId, accessToken, apiClient) {
|
onLoggedIn: function (serverAddress, userId, accessToken, apiClient) {
|
||||||
|
|
||||||
if (Dashboard.isConnectMode()) {
|
if (Dashboard.isConnectMode()) {
|
||||||
Dashboard.serverAddress(serverAddress);
|
Dashboard.serverAddress(serverAddress);
|
||||||
}
|
}
|
||||||
|
@ -1811,6 +1811,14 @@ var AppInfo = {};
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
return false;
|
return false;
|
||||||
});
|
});
|
||||||
|
|
||||||
|
if (Dashboard.isRunningInCordova()) {
|
||||||
|
requirejs(['thirdparty/cordova/chromecast']);
|
||||||
|
} else {
|
||||||
|
if ($.browser.chrome) {
|
||||||
|
requirejs(['scripts/chromecast']);
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
requirejs.config({
|
requirejs.config({
|
||||||
|
|
1
dashboard-ui/thirdparty/cordova/chromecast.js
vendored
Normal file
1
dashboard-ui/thirdparty/cordova/chromecast.js
vendored
Normal file
|
@ -0,0 +1 @@
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue