mirror of
https://github.com/jellyfin/jellyfin-web.git
synced 2024-11-17 19:08:18 -07:00
use shared playerselection
This commit is contained in:
parent
db9eb799d9
commit
bd5d600bd8
@ -14,12 +14,12 @@
|
||||
},
|
||||
"devDependencies": {},
|
||||
"ignore": [],
|
||||
"version": "1.4.476",
|
||||
"_release": "1.4.476",
|
||||
"version": "1.4.477",
|
||||
"_release": "1.4.477",
|
||||
"_resolution": {
|
||||
"type": "version",
|
||||
"tag": "1.4.476",
|
||||
"commit": "802991db23eeaba201548ad9987282a2cab2671a"
|
||||
"tag": "1.4.477",
|
||||
"commit": "15c8b92f1398ccfe25f1d820994c162453f529cf"
|
||||
},
|
||||
"_source": "https://github.com/MediaBrowser/emby-webcomponents.git",
|
||||
"_target": "^1.2.1",
|
||||
|
@ -845,10 +845,6 @@ define(['events', 'datetime', 'appSettings', 'pluginManager', 'userSettings', 'g
|
||||
|
||||
var val = enabled ? '1' : '0';
|
||||
appSettings.set('displaymirror', val);
|
||||
|
||||
if (enabled) {
|
||||
mirrorIfEnabled();
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
define(['appSettings', 'events', 'browser', 'libraryMenu', 'loading', 'playbackManager'], function (appSettings, events, browser, libraryMenu, loading, playbackManager) {
|
||||
define(['appSettings', 'events', 'browser', 'libraryMenu', 'loading', 'playbackManager', 'embyRouter', 'globalize'], function (appSettings, events, browser, libraryMenu, loading, playbackManager, embyRouter, globalize) {
|
||||
'use strict';
|
||||
|
||||
var currentDisplayInfo;
|
||||
@ -25,7 +25,7 @@
|
||||
var player = playbackManager.getPlayerInfo();
|
||||
|
||||
if (player) {
|
||||
if (!player.isLocalPlayer && player.supportedCommands.indexOf('DisplayContent') != -1) {
|
||||
if (!player.isLocalPlayer && player.supportedCommands.indexOf('DisplayContent') !== -1) {
|
||||
mirrorItem(info, player);
|
||||
}
|
||||
}
|
||||
@ -53,7 +53,7 @@
|
||||
|
||||
var name = t.name;
|
||||
|
||||
if (t.appName && t.appName != t.name) {
|
||||
if (t.appName && t.appName !== t.name) {
|
||||
name += " - " + t.appName;
|
||||
}
|
||||
|
||||
@ -70,12 +70,11 @@
|
||||
loading.hide();
|
||||
|
||||
var menuOptions = {
|
||||
title: Globalize.translate('HeaderSelectPlayer'),
|
||||
title: globalize.translate('sharedcomponents#HeaderSelectPlayer'),
|
||||
items: menuItems,
|
||||
positionTo: button,
|
||||
|
||||
resolveOnClick: true
|
||||
|
||||
};
|
||||
|
||||
// Unfortunately we can't allow the url to change or chromecast will throw a security error
|
||||
@ -87,7 +86,7 @@
|
||||
actionsheet.show(menuOptions).then(function (id) {
|
||||
|
||||
var target = targets.filter(function (t) {
|
||||
return t.id == id;
|
||||
return t.id === id;
|
||||
})[0];
|
||||
|
||||
playbackManager.trySetActivePlayer(target.playerName, target);
|
||||
@ -130,12 +129,12 @@
|
||||
|
||||
html += '<div>';
|
||||
|
||||
if (playerInfo.supportedCommands.indexOf('DisplayContent') != -1) {
|
||||
if (playerInfo.supportedCommands.indexOf('DisplayContent') !== -1) {
|
||||
|
||||
html += '<label class="checkboxContainer">';
|
||||
var checkedHtml = playbackManager.enableDisplayMirroring() ? ' checked' : '';
|
||||
html += '<input type="checkbox" is="emby-checkbox" class="chkMirror"' + checkedHtml + '/>';
|
||||
html += '<span>' + Globalize.translate('OptionEnableDisplayMirroring') + '</span>';
|
||||
html += '<span>' + globalize.translate('sharedcomponents#EnableDisplayMirroring') + '</span>';
|
||||
html += '</label>';
|
||||
}
|
||||
|
||||
@ -143,9 +142,9 @@
|
||||
|
||||
html += '<div style="margin-top:1em;display:flex;justify-content: flex-end;">';
|
||||
|
||||
html += '<button is="emby-button" type="button" class="button-flat button-accent-flat btnRemoteControl promptDialogButton">' + Globalize.translate('ButtonRemoteControl') + '</button>';
|
||||
html += '<button is="emby-button" type="button" class="button-flat button-accent-flat btnDisconnect promptDialogButton ">' + Globalize.translate('ButtonDisconnect') + '</button>';
|
||||
html += '<button is="emby-button" type="button" class="button-flat button-accent-flat btnCancel promptDialogButton">' + Globalize.translate('ButtonCancel') + '</button>';
|
||||
html += '<button is="emby-button" type="button" class="button-flat button-accent-flat btnRemoteControl promptDialogButton">' + globalize.translate('sharedcomponents#HeaderRemoteControl') + '</button>';
|
||||
html += '<button is="emby-button" type="button" class="button-flat button-accent-flat btnDisconnect promptDialogButton ">' + globalize.translate('sharedcomponents#Disconnect') + '</button>';
|
||||
html += '<button is="emby-button" type="button" class="button-flat button-accent-flat btnCancel promptDialogButton">' + globalize.translate('sharedcomponents#ButtonCancel') + '</button>';
|
||||
html += '</div>';
|
||||
|
||||
html += '</div>';
|
||||
@ -178,7 +177,7 @@
|
||||
|
||||
dialogHelper.open(dlg).then(function () {
|
||||
if (destination) {
|
||||
Dashboard.navigate(destination);
|
||||
embyRouter.show(destination);
|
||||
}
|
||||
});
|
||||
}
|
||||
@ -204,17 +203,27 @@
|
||||
document.addEventListener('headercreated', bindCastButton);
|
||||
bindCastButton();
|
||||
|
||||
pageClassOn('pagebeforeshow', "page", function () {
|
||||
|
||||
var page = this;
|
||||
|
||||
document.addEventListener('viewbeforeshow', function () {
|
||||
currentDisplayInfo = null;
|
||||
});
|
||||
|
||||
pageClassOn('displayingitem', "libraryPage", function (e) {
|
||||
document.addEventListener('viewshow', function (e) {
|
||||
|
||||
var info = e.detail;
|
||||
mirrorIfEnabled(info);
|
||||
var state = e.detail.state || {};
|
||||
var item = state.item;
|
||||
|
||||
if (item && item.ServerId) {
|
||||
mirrorIfEnabled({
|
||||
item: item
|
||||
});
|
||||
return;
|
||||
}
|
||||
});
|
||||
|
||||
events.on(appSettings, 'change', function (e, name) {
|
||||
if (name === 'displaymirror') {
|
||||
mirrorIfEnabled();
|
||||
}
|
||||
});
|
||||
|
||||
return {
|
@ -115,7 +115,7 @@
|
||||
"RefreshDialogHelp": "Metadata opdateres alt efter hvilke indstillinger og internet-servicer der er aktiveret i Emby Server-kontrolpanelet.",
|
||||
"Open": "\u00c5ben",
|
||||
"Play": "Afspil",
|
||||
"AddToPlayQueue": "Add to play queue",
|
||||
"AddToPlayQueue": "Tilf\u00f8j til afspilningsk\u00f8",
|
||||
"Shuffle": "Bland",
|
||||
"Identify": "Identificer",
|
||||
"EditImages": "Rediger billeder",
|
||||
@ -378,6 +378,6 @@
|
||||
"SyncJobItemStatusCancelled": "Annulleret",
|
||||
"Retry": "Pr\u00f8v igen",
|
||||
"HeaderMyDevice": "Min Enhed",
|
||||
"Continue": "Continue",
|
||||
"ContinueInSecondsValue": "Continue in {0} seconds."
|
||||
"Continue": "Forts\u00e6t",
|
||||
"ContinueInSecondsValue": "Forts\u00e6t om {0} sekunder."
|
||||
}
|
@ -379,5 +379,9 @@
|
||||
"Retry": "Retry",
|
||||
"HeaderMyDevice": "My Device",
|
||||
"Continue": "Continue",
|
||||
"ContinueInSecondsValue": "Continue in {0} seconds."
|
||||
"ContinueInSecondsValue": "Continue in {0} seconds.",
|
||||
"HeaderRemoteControl": "Remote Control",
|
||||
"Disconnect": "Disconnect",
|
||||
"EnableDisplayMirroring": "Enable display mirroring",
|
||||
"HeaderSelectPlayer": "Select Player"
|
||||
}
|
@ -115,7 +115,7 @@
|
||||
"RefreshDialogHelp": "Los metadatos son actualizados bas\u00e1ndose en las configuraciones y servicios de internet que que est\u00e9n activados en el panel de control de su Servidor de Emby.",
|
||||
"Open": "Abrir",
|
||||
"Play": "Reproducir",
|
||||
"AddToPlayQueue": "Add to play queue",
|
||||
"AddToPlayQueue": "Agregar a la cola de reproduccion",
|
||||
"Shuffle": "Aleatorio",
|
||||
"Identify": "Identificar",
|
||||
"EditImages": "Editar im\u00e1genes",
|
||||
@ -378,6 +378,6 @@
|
||||
"SyncJobItemStatusCancelled": "Cancelado",
|
||||
"Retry": "Volver a intentar",
|
||||
"HeaderMyDevice": "Mi Dispositivo",
|
||||
"Continue": "Continue",
|
||||
"ContinueInSecondsValue": "Continue in {0} seconds."
|
||||
"Continue": "Continuar",
|
||||
"ContinueInSecondsValue": "Continua en {0} segundos."
|
||||
}
|
@ -1029,7 +1029,7 @@ var AppInfo = {};
|
||||
define("directorybrowser", ["components/directorybrowser/directorybrowser"], returnFirstDependency);
|
||||
define("metadataEditor", [embyWebComponentsBowerPath + "/metadataeditor/metadataeditor"], returnFirstDependency);
|
||||
define("personEditor", [embyWebComponentsBowerPath + "/metadataeditor/personeditor"], returnFirstDependency);
|
||||
define("playerSelectionMenu", ["components/playerselection"], returnFirstDependency);
|
||||
define("playerSelectionMenu", [embyWebComponentsBowerPath + "/playback/playerselection"], returnFirstDependency);
|
||||
|
||||
define("libraryMenu", ["scripts/librarymenu"], returnFirstDependency);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user