mirror of
https://github.com/redphx/better-xcloud.git
synced 2025-06-06 15:47:18 +02:00
Disable "Visual quality" setting on unsupported browsers
This commit is contained in:
parent
1f787b7888
commit
7a202ba8a7
@ -3591,7 +3591,13 @@ function injectSettingsButton($parent) {
|
||||
}
|
||||
|
||||
// Disable unsupported settings
|
||||
if (!HAS_TOUCH_SUPPORT) {
|
||||
if (settingId === Preferences.STREAM_CODEC_PROFILE) {
|
||||
const options = Preferences.SETTINGS[Preferences.STREAM_CODEC_PROFILE].options;
|
||||
if (Object.keys(options).length <= 1) {
|
||||
$control.disabled = true;
|
||||
$control.title = __('browser-unsupported-feature');
|
||||
}
|
||||
} else if (!HAS_TOUCH_SUPPORT) {
|
||||
// Disable this setting for non-touchable devices
|
||||
if ([Preferences.STREAM_TOUCH_CONTROLLER, Preferences.STREAM_TOUCH_CONTROLLER_STYLE_STANDARD, Preferences.STREAM_TOUCH_CONTROLLER_STYLE_CUSTOM].indexOf(settingId) > -1) {
|
||||
$control.disabled = true;
|
||||
|
Loading…
x
Reference in New Issue
Block a user