mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
update cinema mode on/off setting
This commit is contained in:
parent
8fe136f23c
commit
ab30128e67
8 changed files with 40 additions and 13 deletions
|
@ -411,7 +411,8 @@
|
|||
throw new Error("Cannot open web socket without access token.");
|
||||
}
|
||||
|
||||
var url = self.getUrl("socket").replace("/socket", "").replace('http', 'ws');
|
||||
var url = self.getUrl("socket").replace("emby/socket", "embywebsocket").replace('http', 'ws');
|
||||
|
||||
url += "?api_key=" + accessToken;
|
||||
url += "&deviceId=" + deviceId;
|
||||
|
||||
|
|
|
@ -39,6 +39,6 @@
|
|||
"commit": "cec8e49744a1e18b14a711eea77e201bb70de544"
|
||||
},
|
||||
"_source": "git://github.com/desandro/doc-ready.git",
|
||||
"_target": "1.0.x",
|
||||
"_target": "~1.0.4",
|
||||
"_originalSource": "doc-ready"
|
||||
}
|
|
@ -30,14 +30,14 @@
|
|||
"webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0"
|
||||
},
|
||||
"ignore": [],
|
||||
"homepage": "https://github.com/PolymerElements/iron-a11y-keys-behavior",
|
||||
"homepage": "https://github.com/polymerelements/iron-a11y-keys-behavior",
|
||||
"_release": "1.0.9",
|
||||
"_resolution": {
|
||||
"type": "version",
|
||||
"tag": "v1.0.9",
|
||||
"commit": "63dd1ce94223ae6a226e653ef5a458a66c950e79"
|
||||
},
|
||||
"_source": "git://github.com/PolymerElements/iron-a11y-keys-behavior.git",
|
||||
"_source": "git://github.com/polymerelements/iron-a11y-keys-behavior.git",
|
||||
"_target": "^1.0.0",
|
||||
"_originalSource": "PolymerElements/iron-a11y-keys-behavior"
|
||||
"_originalSource": "polymerelements/iron-a11y-keys-behavior"
|
||||
}
|
|
@ -36,7 +36,7 @@
|
|||
"tag": "v1.0.8",
|
||||
"commit": "e9a66727f3da0446f04956d4e4f1dcd51cdec2ff"
|
||||
},
|
||||
"_source": "git://github.com/PolymerElements/iron-selector.git",
|
||||
"_source": "git://github.com/polymerelements/iron-selector.git",
|
||||
"_target": "^1.0.0",
|
||||
"_originalSource": "PolymerElements/iron-selector"
|
||||
"_originalSource": "polymerelements/iron-selector"
|
||||
}
|
|
@ -48,7 +48,7 @@
|
|||
</div>
|
||||
<div class="detailSection cinemaModeOptions" style="display:none;">
|
||||
<h1>
|
||||
${HeaderCinemaMode}<span style="color:#52B54B;margin-left:.5em;">*</span>
|
||||
${HeaderCinemaMode}
|
||||
</h1>
|
||||
<div class="detailSectionContent">
|
||||
<br />
|
||||
|
|
|
@ -56,6 +56,24 @@
|
|||
|
||||
return appStorage.getItem('externalplayers') == 'true';
|
||||
},
|
||||
enableCinemaMode: function (val) {
|
||||
|
||||
if (val != null) {
|
||||
update('enableCinemaMode', val.toString());
|
||||
}
|
||||
|
||||
val = appStorage.getItem('enableCinemaMode');
|
||||
|
||||
if (val) {
|
||||
return val != 'false';
|
||||
}
|
||||
|
||||
if ($.browser.mobile) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
},
|
||||
enableFullScreen: function (val) {
|
||||
|
||||
if (val != null) {
|
||||
|
|
|
@ -36,9 +36,6 @@
|
|||
return targets;
|
||||
};
|
||||
|
||||
var canPlayAac = document.createElement('audio').canPlayType('audio/aac').replace(/no/, '');
|
||||
var canPlayMp3 = document.createElement('audio').canPlayType('audio/mp3').replace(/no/, '');
|
||||
|
||||
self.getVideoQualityOptions = function (videoWidth, videoHeight) {
|
||||
|
||||
var bitrateSetting = AppSettings.maxStreamingBitrate();
|
||||
|
@ -130,6 +127,8 @@
|
|||
|
||||
var canPlayWebm = supportedFormats.indexOf('webm') != -1;
|
||||
var canPlayAc3 = supportedFormats.indexOf('ac3') != -1;
|
||||
var canPlayAac = supportedFormats.indexOf('aac') != -1;
|
||||
var canPlayMp3 = supportedFormats.indexOf('mp3') != -1;
|
||||
|
||||
var profile = {};
|
||||
|
||||
|
@ -1868,6 +1867,14 @@
|
|||
if (canPlayH264) {
|
||||
list.push('h264');
|
||||
}
|
||||
|
||||
if (document.createElement('audio').canPlayType('audio/aac').replace(/no/, '')) {
|
||||
list.push('aac');
|
||||
}
|
||||
if (document.createElement('audio').canPlayType('audio/mp3').replace(/no/, '')) {
|
||||
list.push('mp3');
|
||||
}
|
||||
|
||||
supportedFormats = list;
|
||||
return list;
|
||||
}
|
||||
|
|
|
@ -30,7 +30,7 @@
|
|||
$('#selectSubtitlePlaybackMode', page).val(user.Configuration.SubtitleMode || "").trigger('change');
|
||||
|
||||
page.querySelector('.chkPlayDefaultAudioTrack').checked = user.Configuration.PlayDefaultAudioTrack || false;
|
||||
page.querySelector('.chkEnableCinemaMode').checked = user.Configuration.EnableCinemaMode || false;
|
||||
page.querySelector('.chkEnableCinemaMode').checked = AppSettings.enableCinemaMode();
|
||||
page.querySelector('.chkEnableChromecastAc3').checked = AppSettings.enableChromecastAc3();
|
||||
page.querySelector('.chkExternalVideoPlayer').checked = AppSettings.enableExternalPlayers();
|
||||
|
||||
|
@ -90,7 +90,8 @@
|
|||
|
||||
user.Configuration.SubtitleMode = $('#selectSubtitlePlaybackMode', page).val();
|
||||
user.Configuration.PlayDefaultAudioTrack = page.querySelector('.chkPlayDefaultAudioTrack').checked;
|
||||
user.Configuration.EnableCinemaMode = page.querySelector('.chkEnableCinemaMode').checked;
|
||||
|
||||
AppSettings.enableCinemaMode(page.querySelector('.chkEnableCinemaMode').checked);
|
||||
|
||||
ApiClient.updateUserConfiguration(user.Id, user.Configuration).done(function () {
|
||||
Dashboard.alert(Globalize.translate('SettingsSaved'));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue