From 78f79653049baff0ec6514b743e5f602d43ad391 Mon Sep 17 00:00:00 2001 From: Flashfyre Date: Wed, 15 May 2024 12:22:32 -0400 Subject: [PATCH] Revert "add logic to conditionally align window (#851)" This reverts commit 7769c06393d5a0f96002e31d438ad640ee58e720. --- src/system/settings.ts | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/src/system/settings.ts b/src/system/settings.ts index 91d6459e4..15c1f19aa 100644 --- a/src/system/settings.ts +++ b/src/system/settings.ts @@ -2,7 +2,7 @@ import SettingsUiHandler from "#app/ui/settings-ui-handler"; import { Mode } from "#app/ui/ui"; import i18next from "i18next"; import BattleScene from "../battle-scene"; -import { hasTouchscreen, isMobile } from "../touch-controls"; +import { hasTouchscreen } from "../touch-controls"; import { updateWindowType } from "../ui/ui-theme"; import { PlayerGender } from "./game-data"; @@ -167,14 +167,6 @@ export function setSetting(scene: BattleScene, setting: Setting, value: integer) const touchControls = document.getElementById('touchControls'); if (touchControls) touchControls.classList.toggle('visible', scene.enableTouchControls); - - const isLandscape = window.matchMedia("(orientation: landscape)").matches; - const appContainer = document.getElementById('app'); - - if (!isMobile() && isLandscape && !scene.enableTouchControls) - appContainer.style.alignItems = 'center'; - else - appContainer.style.alignItems = 'start'; break; case Setting.Vibration: scene.enableVibration = settingOptions[setting][value] !== 'Disabled' && hasTouchscreen();