Hide touchscreen using bx-offscreen instead of bx-gone

This commit is contained in:
redphx 2024-02-02 10:02:57 +07:00
parent fdbf618253
commit 966d7f2f6c

View File

@ -3434,14 +3434,12 @@ class TouchController {
} }
static #show() { static #show() {
document.querySelector('#BabylonCanvasContainer-main').parentElement.classList.remove('bx-gone'); document.querySelector('#BabylonCanvasContainer-main').parentElement.classList.remove('bx-offscreen');
// TouchController.loadCustomLayout(GAME_XBOX_TITLE_ID, TouchController.#currentLayoutId, 0);
TouchController.#showing = true; TouchController.#showing = true;
} }
static #hide() { static #hide() {
document.querySelector('#BabylonCanvasContainer-main').parentElement.classList.add('bx-gone'); document.querySelector('#BabylonCanvasContainer-main').parentElement.classList.add('bx-offscreen');
// TouchController.#dispatchMessage(TouchController.#EVENT_HIDE_CONTROLLER);
TouchController.#showing = false; TouchController.#showing = false;
} }