Hide enableGamepad on UWP and DisplayMode on Xbox.

This commit is contained in:
Bradley Eaton
2025-06-30 17:04:15 +01:00
parent 12bbcb0048
commit fe3adb2ba6
3 changed files with 12 additions and 2 deletions

View File

@@ -265,7 +265,11 @@ const supportedFeatures = function () {
}
features.push(AppFeature.DisplayLanguage);
features.push(AppFeature.DisplayMode);
if (!browser.xboxOne) {
features.push(AppFeature.DisplayMode);
}
features.push(AppFeature.TargetBlank);
features.push(AppFeature.Screensaver);

View File

@@ -6,7 +6,7 @@
${Controls}
</h2>
<div class="checkboxContainer checkboxContainer-withDescription">
<div class="checkboxContainer checkboxContainer-withDescription enableGamepadContainer hide">
<label>
<input type="checkbox" is="emby-checkbox" class="chkEnableGamepad" />
<span>${LabelEnableGamepad}</span>

View File

@@ -3,6 +3,7 @@ import toast from '../../../components/toast/toast';
import globalize from '../../../lib/globalize';
import appSettings from '../../../scripts/settings/appSettings';
import Events from '../../../utils/events.ts';
import browser from 'scripts/browser';
export default function (view) {
function submit(e) {
@@ -21,6 +22,11 @@ export default function (view) {
view.addEventListener('viewshow', function () {
view.querySelector('.smoothScrollContainer').classList.toggle('hide', !layoutManager.tv);
if (browser.edgeUwp) {
view.querySelector('.enableGamepadContainer').classList.add('hide');
} else {
view.querySelector('.enableGamepadContainer').classList.remove('hide');
}
view.querySelector('.chkEnableGamepad').checked = appSettings.enableGamepad();
view.querySelector('.chkSmoothScroll').checked = appSettings.enableSmoothScroll();