mirror of
https://github.com/redphx/better-xcloud.git
synced 2025-08-02 03:16:42 +02:00
Add BX_EXPOSED.backButtonPressed()
This commit is contained in:
@@ -4,6 +4,7 @@ import { deepClone, STATES } from "@utils/global";
|
||||
import { getPref, PrefKey } from "@utils/preferences";
|
||||
import { BxLogger } from "./bx-logger";
|
||||
import { BX_FLAGS } from "./bx-flags";
|
||||
import { StreamSettings } from "@/modules/stream/stream-settings";
|
||||
|
||||
export enum InputType {
|
||||
CONTROLLER = 'Controller',
|
||||
@@ -117,4 +118,14 @@ export const BxExposed = {
|
||||
},
|
||||
|
||||
disableGamepadPolling: false,
|
||||
|
||||
backButtonPressed: () => {
|
||||
const streamSettings = StreamSettings.getInstance();
|
||||
if (streamSettings.isShowing()) {
|
||||
streamSettings.hide();
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
},
|
||||
};
|
||||
|
Reference in New Issue
Block a user