mirror of
https://github.com/redphx/better-xcloud.git
synced 2025-08-06 13:18:27 +02:00
Add setting to enable/disable Game Bar feature
This commit is contained in:
15
src/index.ts
15
src/index.ts
@@ -149,12 +149,17 @@ window.addEventListener(BxEvent.STREAM_PLAYING, e => {
|
||||
STATES.isPlaying = true;
|
||||
injectStreamMenuButtons();
|
||||
|
||||
GameBar.reset();
|
||||
GameBar.enable();
|
||||
GameBar.showBar();
|
||||
if (getPref(PrefKey.GAME_BAR_ENABLED)) {
|
||||
GameBar.reset();
|
||||
GameBar.enable();
|
||||
GameBar.showBar();
|
||||
}
|
||||
|
||||
if (STATES.currentStream.$screenshotCanvas) {
|
||||
STATES.currentStream.$screenshotCanvas.width = $video.videoWidth;
|
||||
STATES.currentStream.$screenshotCanvas.height = $video.videoHeight;
|
||||
}
|
||||
|
||||
STATES.currentStream.$screenshotCanvas!.width = $video.videoWidth;
|
||||
STATES.currentStream.$screenshotCanvas!.height = $video.videoHeight;
|
||||
updateVideoPlayerCss();
|
||||
});
|
||||
|
||||
|
Reference in New Issue
Block a user