mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
3.0.5231.40980
This commit is contained in:
parent
ee5eefb01e
commit
8a5cd4b491
13 changed files with 68 additions and 42 deletions
|
@ -587,7 +587,7 @@
|
|||
this.timer = setInterval(this.incrementMediaTimeHandler, this.timerStep);
|
||||
};
|
||||
|
||||
var castPlayer = new CastPlayer();
|
||||
//var castPlayer = new CastPlayer();
|
||||
|
||||
function getCodecLimits() {
|
||||
|
||||
|
@ -1477,16 +1477,16 @@
|
|||
};
|
||||
}
|
||||
|
||||
MediaController.registerPlayer(new chromecastPlayer());
|
||||
//MediaController.registerPlayer(new chromecastPlayer());
|
||||
|
||||
$(MediaController).on('playerchange', function () {
|
||||
//$(MediaController).on('playerchange', function () {
|
||||
|
||||
if (MediaController.getPlayerInfo().name == PlayerName) {
|
||||
// if (MediaController.getPlayerInfo().name == PlayerName) {
|
||||
|
||||
if (castPlayer.deviceState != DEVICE_STATE.ACTIVE && castPlayer.isInitialized) {
|
||||
castPlayer.launchApp();
|
||||
}
|
||||
}
|
||||
});
|
||||
// if (castPlayer.deviceState != DEVICE_STATE.ACTIVE && castPlayer.isInitialized) {
|
||||
// castPlayer.launchApp();
|
||||
// }
|
||||
// }
|
||||
//});
|
||||
|
||||
})(window, window.chrome, console);
|
|
@ -16,7 +16,7 @@
|
|||
|
||||
html += '<a class="desktopHomeLink" href="index.html"><img src="css/images/mblogoicon.png" /></a>';
|
||||
|
||||
html += '<a class="viewMenuRemoteControlButton" href="nowplaying.html" data-role="button" data-icon="play" data-inline="true" data-iconpos="notext" title="Now Playing">Remote Control</a>';
|
||||
html += '<a class="viewMenuRemoteControlButton" href="nowplaying.html" data-role="button" data-icon="play" data-inline="true" data-iconpos="notext" title="Now Playing" style="display:none;">Remote Control</a>';
|
||||
|
||||
if (user.Configuration.IsAdministrator) {
|
||||
html += '<a class="editorMenuLink" href="edititemmetadata.html" data-role="button" data-icon="edit" data-inline="true" data-iconpos="notext" title="Metadata Manager">Metadata Manager</a>';
|
||||
|
|
|
@ -10,8 +10,7 @@
|
|||
IncludeItemTypes: "Movie",
|
||||
Recursive: true,
|
||||
Fields: "PrimaryImageAspectRatio",
|
||||
StartIndex: 0,
|
||||
CollapseBoxSetItems: true
|
||||
StartIndex: 0
|
||||
};
|
||||
|
||||
function reloadItems(page) {
|
||||
|
|
|
@ -388,7 +388,7 @@
|
|||
|
||||
player.getPlayerState().done(function (state) {
|
||||
|
||||
if (state.itemName) {
|
||||
if (state.NowPlayingItem) {
|
||||
player.beginPlayerUpdates();
|
||||
}
|
||||
|
||||
|
|
|
@ -89,9 +89,9 @@
|
|||
|
||||
$('.btnToggleFullscreen', page).buttonEnabled(item && item.MediaType == 'Video' && supportedCommands.indexOf('ToggleFullscreen') != -1);
|
||||
|
||||
$('.btnAudioTracks', page).buttonEnabled(item != null);
|
||||
$('.btnSubtitles', page).buttonEnabled(item != null);
|
||||
$('.btnChapters', page).buttonEnabled(item != null);
|
||||
$('.btnAudioTracks', page).buttonEnabled(false);
|
||||
$('.btnSubtitles', page).buttonEnabled(false);
|
||||
$('.btnChapters', page).buttonEnabled(false);
|
||||
|
||||
$('.btnStop', page).buttonEnabled(item != null);
|
||||
$('.btnNextTrack', page).buttonEnabled(item != null);
|
||||
|
@ -142,7 +142,7 @@
|
|||
|
||||
player.getPlayerState().done(function (state) {
|
||||
|
||||
if (state.itemName) {
|
||||
if (state.NowPlayingItem) {
|
||||
player.beginPlayerUpdates();
|
||||
}
|
||||
|
||||
|
@ -168,6 +168,13 @@
|
|||
|
||||
bindEvents(page);
|
||||
|
||||
}).on('pageshow', "#nowPlayingPage", function () {
|
||||
|
||||
var page = this;
|
||||
|
||||
$('.radioTabButton', page).checked(false).checkboxradio('refresh');
|
||||
$('.radioTabButton:first', page).checked(true).checkboxradio('refresh').trigger('change');
|
||||
|
||||
$(function () {
|
||||
|
||||
$(MediaController).on('playerchange.nowplayingpage', function () {
|
||||
|
@ -179,13 +186,6 @@
|
|||
|
||||
});
|
||||
|
||||
}).on('pageshow', "#nowPlayingPage", function () {
|
||||
|
||||
var page = this;
|
||||
|
||||
$('.radioTabButton', page).checked(false).checkboxradio('refresh');
|
||||
$('.radioTabButton:first', page).checked(true).checkboxradio('refresh').trigger('change');
|
||||
|
||||
}).on('pagehide', "#nowPlayingPage", function () {
|
||||
|
||||
releaseCurrentPlayer();
|
||||
|
|
|
@ -167,16 +167,20 @@
|
|||
return deferred.promise();
|
||||
};
|
||||
|
||||
function subscribeToPlayerUpdates() {
|
||||
self.subscribeToPlayerUpdates = function () {
|
||||
|
||||
self.isUpdating = true;
|
||||
|
||||
if (ApiClient.isWebSocketOpen()) {
|
||||
|
||||
ApiClient.sendWebSocketMessage("SessionsStart", "100,700");
|
||||
ApiClient.sendWebSocketMessage("SessionsStart", "100,900");
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
function unsubscribeFromPlayerUpdates() {
|
||||
|
||||
self.false = true;
|
||||
|
||||
if (ApiClient.isWebSocketOpen()) {
|
||||
|
||||
ApiClient.sendWebSocketMessage("SessionsStop");
|
||||
|
@ -190,7 +194,7 @@
|
|||
|
||||
playerListenerCount = 0;
|
||||
|
||||
subscribeToPlayerUpdates();
|
||||
self.subscribeToPlayerUpdates();
|
||||
}
|
||||
|
||||
playerListenerCount++;
|
||||
|
@ -259,6 +263,14 @@
|
|||
$(player).trigger(name, [getPlayerState(session)]);
|
||||
}
|
||||
|
||||
function onWebSocketConnectionChange() {
|
||||
|
||||
// Reconnect
|
||||
if (player.isUpdating) {
|
||||
player.subscribeToPlayerUpdates();
|
||||
}
|
||||
}
|
||||
|
||||
function onWebSocketMessageReceived(e, msg) {
|
||||
|
||||
if (msg.MessageType === "Sessions") {
|
||||
|
@ -291,6 +303,6 @@
|
|||
}
|
||||
}
|
||||
|
||||
$(ApiClient).on("websocketmessage", onWebSocketMessageReceived);
|
||||
$(ApiClient).on("websocketmessage", onWebSocketMessageReceived).on("websocketopen", onWebSocketConnectionChange);
|
||||
|
||||
})(window, document, jQuery);
|
|
@ -33,6 +33,8 @@
|
|||
$('#chkDisplayMissingEpisodes', page).checked(user.Configuration.DisplayMissingEpisodes || false).checkboxradio("refresh");
|
||||
$('#chkDisplayUnairedEpisodes', page).checked(user.Configuration.DisplayUnairedEpisodes || false).checkboxradio("refresh");
|
||||
|
||||
$('#chkGroupMoviesIntoCollections', page).checked(user.Configuration.GroupMoviesIntoBoxSets || false).checkboxradio("refresh");
|
||||
|
||||
Dashboard.hideLoadingMsg();
|
||||
}
|
||||
|
||||
|
@ -58,6 +60,7 @@
|
|||
user.Configuration.UseForcedSubtitlesOnly = $('#chkForcedSubtitlesOnly', page).checked();
|
||||
user.Configuration.DisplayMissingEpisodes = $('#chkDisplayMissingEpisodes', page).checked();
|
||||
user.Configuration.DisplayUnairedEpisodes = $('#chkDisplayUnairedEpisodes', page).checked();
|
||||
user.Configuration.GroupMoviesIntoBoxSets = $('#chkGroupMoviesIntoCollections', page).checked();
|
||||
|
||||
ApiClient.updateUser(user).done(function () {
|
||||
onSaveComplete(page);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue