mirror of
https://github.com/stashapp/stash.git
synced 2025-12-16 20:07:05 +03:00
Add support for disabling mobile media-viewer's fullscreen auto-rotate (#4416)
This commit is contained in:
@@ -539,7 +539,6 @@ func TestMain(m *testing.M) {
|
|||||||
// initialise empty config - needed by some migrations
|
// initialise empty config - needed by some migrations
|
||||||
_ = config.InitializeEmpty()
|
_ = config.InitializeEmpty()
|
||||||
|
|
||||||
|
|
||||||
ret := runTests(m)
|
ret := runTests(m)
|
||||||
os.Exit(ret)
|
os.Exit(ret)
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -553,7 +553,9 @@ export const ScenePlayer: React.FC<IScenePlayerProps> = ({
|
|||||||
enterOnRotate: true,
|
enterOnRotate: true,
|
||||||
exitOnRotate: true,
|
exitOnRotate: true,
|
||||||
lockOnRotate: true,
|
lockOnRotate: true,
|
||||||
lockToLandscapeOnEnter: isLandscape,
|
lockToLandscapeOnEnter: uiConfig?.disableMobileMediaAutoRotateEnabled
|
||||||
|
? false
|
||||||
|
: isLandscape,
|
||||||
},
|
},
|
||||||
touchControls: {
|
touchControls: {
|
||||||
disabled: true,
|
disabled: true,
|
||||||
@@ -679,6 +681,7 @@ export const ScenePlayer: React.FC<IScenePlayerProps> = ({
|
|||||||
autoplay,
|
autoplay,
|
||||||
interfaceConfig?.autostartVideo,
|
interfaceConfig?.autostartVideo,
|
||||||
uiConfig?.alwaysStartFromBeginning,
|
uiConfig?.alwaysStartFromBeginning,
|
||||||
|
uiConfig?.disableMobileMediaAutoRotateEnabled,
|
||||||
_initialTimestamp,
|
_initialTimestamp,
|
||||||
]);
|
]);
|
||||||
|
|
||||||
|
|||||||
@@ -278,6 +278,12 @@ export const SettingsInterfacePanel: React.FC = () => {
|
|||||||
checked={ui.enableChromecast ?? undefined}
|
checked={ui.enableChromecast ?? undefined}
|
||||||
onChange={(v) => saveUI({ enableChromecast: v })}
|
onChange={(v) => saveUI({ enableChromecast: v })}
|
||||||
/>
|
/>
|
||||||
|
<BooleanSetting
|
||||||
|
id="disable-mobile-media-auto-rotate"
|
||||||
|
headingID="config.ui.scene_player.options.disable_mobile_media_auto_rotate"
|
||||||
|
checked={ui.disableMobileMediaAutoRotateEnabled ?? undefined}
|
||||||
|
onChange={(v) => saveUI({ disableMobileMediaAutoRotateEnabled: v })}
|
||||||
|
/>
|
||||||
<BooleanSetting
|
<BooleanSetting
|
||||||
id="show-scrubber"
|
id="show-scrubber"
|
||||||
headingID="config.ui.scene_player.options.show_scrubber"
|
headingID="config.ui.scene_player.options.show_scrubber"
|
||||||
|
|||||||
@@ -60,6 +60,9 @@ export interface IUIConfig {
|
|||||||
// if true the chromecast option will enabled
|
// if true the chromecast option will enabled
|
||||||
enableChromecast?: boolean;
|
enableChromecast?: boolean;
|
||||||
|
|
||||||
|
// if true the fullscreen mobile media auto-rotate option will be disabled
|
||||||
|
disableMobileMediaAutoRotateEnabled?: boolean;
|
||||||
|
|
||||||
// if true continue scene will always play from the beginning
|
// if true continue scene will always play from the beginning
|
||||||
alwaysStartFromBeginning?: boolean;
|
alwaysStartFromBeginning?: boolean;
|
||||||
// if true enable activity tracking
|
// if true enable activity tracking
|
||||||
|
|||||||
@@ -701,6 +701,7 @@
|
|||||||
"heading": "Continue playlist by default"
|
"heading": "Continue playlist by default"
|
||||||
},
|
},
|
||||||
"enable_chromecast": "Enable Chromecast",
|
"enable_chromecast": "Enable Chromecast",
|
||||||
|
"disable_mobile_media_auto_rotate": "Disable auto-rotate of fullscreen media on Mobile",
|
||||||
"show_ab_loop_controls": "Show AB Loop plugin controls",
|
"show_ab_loop_controls": "Show AB Loop plugin controls",
|
||||||
"show_scrubber": "Show Scrubber",
|
"show_scrubber": "Show Scrubber",
|
||||||
"track_activity": "Track Activity",
|
"track_activity": "Track Activity",
|
||||||
|
|||||||
@@ -690,6 +690,7 @@
|
|||||||
"heading": "Continuer la liste de lecture par défaut"
|
"heading": "Continuer la liste de lecture par défaut"
|
||||||
},
|
},
|
||||||
"enable_chromecast": "Activer Chromecast",
|
"enable_chromecast": "Activer Chromecast",
|
||||||
|
"disable_mobile_media_auto_rotate": "Désactiver la rotation automatique des médias en plein écran sur mobile",
|
||||||
"show_scrubber": "Montrer la barre de progression",
|
"show_scrubber": "Montrer la barre de progression",
|
||||||
"track_activity": "Suivre l'activité",
|
"track_activity": "Suivre l'activité",
|
||||||
"vr_tag": {
|
"vr_tag": {
|
||||||
|
|||||||
@@ -680,6 +680,7 @@
|
|||||||
"heading": "VR Tagg"
|
"heading": "VR Tagg"
|
||||||
},
|
},
|
||||||
"enable_chromecast": "Aktivera Chromecast",
|
"enable_chromecast": "Aktivera Chromecast",
|
||||||
|
"disable_mobile_media_auto_rotate": "Inaktivera automatisk rotering av helskärmsmedia på mobil",
|
||||||
"show_ab_loop_controls": "Visa AB-loop plugin kontroller"
|
"show_ab_loop_controls": "Visa AB-loop plugin kontroller"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user