1
0
Fork 0
mirror of https://github.com/jellyfin/jellyfin-web synced 2025-03-30 19:56:21 +00:00

Fix PR issues.

This commit is contained in:
Ian Walton 2020-09-22 07:34:46 -04:00
parent f5311864bc
commit ecad2e4bda
3 changed files with 5 additions and 15 deletions

View file

@ -220,18 +220,16 @@ function showActivePlayerMenuInternal(dialogHelper, playerInfo) {
html += '</label>';
}
html += '</div><div>';
html += '</div>';
if (autocast.supported()) {
html += '<label class="checkboxContainer">';
html += '<div><label class="checkboxContainer">';
var checkedHtmlAC = autocast.isEnabled() ? ' checked' : '';
html += '<input type="checkbox" is="emby-checkbox" class="chkAutoCast"' + checkedHtmlAC + '/>';
html += '<span>' + globalize.translate('EnableAutoCast') + '</span>';
html += '</label>';
html += '</label></div>';
}
html += '</div>';
html += '<div style="margin-top:1em;display:flex;justify-content: flex-end;">';
html += '<button is="emby-button" type="button" class="button-flat btnRemoteControl promptDialogButton">' + globalize.translate('HeaderRemoteControl') + '</button>';

View file

@ -11,7 +11,7 @@ export function enable(enabled) {
if (enabled) {
const currentPlayerInfo = playbackManager.getPlayerInfo();
if (currentPlayerInfo && currentPlayerInfo.id && currentPlayerInfo.id) {
if (currentPlayerInfo && currentPlayerInfo.id) {
localStorage.setItem('autocastPlayerId', currentPlayerInfo.id);
}
} else {
@ -29,8 +29,6 @@ export function isEnabled() {
}
function onOpen() {
if (!supported()) return;
const playerId = localStorage.getItem('autocastPlayerId');
playbackManager.getTargets().then(function (targets) {
@ -44,6 +42,6 @@ function onOpen() {
}
const apiClient = window.connectionManager.currentApiClient();
if (apiClient) {
if (apiClient && supported()) {
events.on(apiClient, 'websocketopen', onOpen);
}

View file

@ -911,12 +911,6 @@ import 'flexStyles';
}
}
function ensureHeader() {
return new Promise(function (resolve) {
window.connectionManager.user(getCurrentApiClient()).then(updateUserInHeader).then(resolve);
});
}
let currentPageType;
pageClassOn('pagebeforeshow', 'page', function (e) {
if (!this.classList.contains('withTabs')) {