mirror of
https://github.com/redphx/better-xcloud.git
synced 2025-06-06 23:57:19 +02:00
Update better-xcloud.user.js
This commit is contained in:
parent
bee190b867
commit
a24446a6b4
19
dist/better-xcloud.user.js
vendored
19
dist/better-xcloud.user.js
vendored
@ -2683,7 +2683,6 @@ function injectStreamMenuButtons() {
|
|||||||
};
|
};
|
||||||
let $btnStreamSettings;
|
let $btnStreamSettings;
|
||||||
let $btnStreamStats;
|
let $btnStreamStats;
|
||||||
const PREF_DISABLE_FEEDBACK_DIALOG = getPref(PrefKey.STREAM_DISABLE_FEEDBACK_DIALOG);
|
|
||||||
const observer = new MutationObserver((mutationList) => {
|
const observer = new MutationObserver((mutationList) => {
|
||||||
mutationList.forEach((item2) => {
|
mutationList.forEach((item2) => {
|
||||||
if (item2.type !== "childList") {
|
if (item2.type !== "childList") {
|
||||||
@ -2709,11 +2708,6 @@ function injectStreamMenuButtons() {
|
|||||||
BxEvent.dispatch(window, BxEvent.STREAM_ERROR_PAGE);
|
BxEvent.dispatch(window, BxEvent.STREAM_ERROR_PAGE);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (PREF_DISABLE_FEEDBACK_DIALOG && $elm.className.startsWith("PostStreamFeedbackScreen")) {
|
|
||||||
const $btnClose = $elm.querySelector("button");
|
|
||||||
$btnClose && $btnClose.click();
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if ($elm.className?.startsWith("StreamMenu-module__container")) {
|
if ($elm.className?.startsWith("StreamMenu-module__container")) {
|
||||||
const $btnCloseHud = document.querySelector("button[class*=StreamMenu-module__backButton]");
|
const $btnCloseHud = document.querySelector("button[class*=StreamMenu-module__backButton]");
|
||||||
if (!$btnCloseHud) {
|
if (!$btnCloseHud) {
|
||||||
@ -3975,10 +3969,10 @@ class LoadingScreen {
|
|||||||
}
|
}
|
||||||
`;
|
`;
|
||||||
}
|
}
|
||||||
LoadingScreen.reset();
|
setTimeout(LoadingScreen.reset, 2000);
|
||||||
}
|
}
|
||||||
static reset() {
|
static reset() {
|
||||||
LoadingScreen.#$bgStyle && setTimeout(() => LoadingScreen.#$bgStyle.textContent = "", 2000);
|
LoadingScreen.#$bgStyle && (LoadingScreen.#$bgStyle.textContent = "");
|
||||||
LoadingScreen.#$waitTimeBox && LoadingScreen.#$waitTimeBox.classList.add("bx-gone");
|
LoadingScreen.#$waitTimeBox && LoadingScreen.#$waitTimeBox.classList.add("bx-gone");
|
||||||
LoadingScreen.#waitTimeInterval && clearInterval(LoadingScreen.#waitTimeInterval);
|
LoadingScreen.#waitTimeInterval && clearInterval(LoadingScreen.#waitTimeInterval);
|
||||||
LoadingScreen.#waitTimeInterval = null;
|
LoadingScreen.#waitTimeInterval = null;
|
||||||
@ -7715,6 +7709,14 @@ window.dispatchEvent(new Event('${BxEvent.STREAM_SESSION_READY}'))
|
|||||||
true` + text;
|
true` + text;
|
||||||
str2 = str2.replace(text, newCode);
|
str2 = str2.replace(text, newCode);
|
||||||
return str2;
|
return str2;
|
||||||
|
},
|
||||||
|
skipFeedbackDialog(str2) {
|
||||||
|
const text = "&&this.shouldTransitionToFeedback(";
|
||||||
|
if (!str2.includes(text)) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
str2 = str2.replace(text, "&& false " + text);
|
||||||
|
return str2;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
var PATCH_ORDERS = [
|
var PATCH_ORDERS = [
|
||||||
@ -7751,6 +7753,7 @@ var PLAYING_PATCH_ORDERS = [
|
|||||||
"playVibration",
|
"playVibration",
|
||||||
getPref(PrefKey.AUDIO_ENABLE_VOLUME_CONTROL) && !getPref(PrefKey.STREAM_COMBINE_SOURCES) && "patchAudioMediaStream",
|
getPref(PrefKey.AUDIO_ENABLE_VOLUME_CONTROL) && !getPref(PrefKey.STREAM_COMBINE_SOURCES) && "patchAudioMediaStream",
|
||||||
getPref(PrefKey.AUDIO_ENABLE_VOLUME_CONTROL) && getPref(PrefKey.STREAM_COMBINE_SOURCES) && "patchCombinedAudioVideoMediaStream",
|
getPref(PrefKey.AUDIO_ENABLE_VOLUME_CONTROL) && getPref(PrefKey.STREAM_COMBINE_SOURCES) && "patchCombinedAudioVideoMediaStream",
|
||||||
|
getPref(PrefKey.STREAM_DISABLE_FEEDBACK_DIALOG) && "skipFeedbackDialog",
|
||||||
STATES.hasTouchSupport && getPref(PrefKey.STREAM_TOUCH_CONTROLLER) === "all" && "patchShowSensorControls",
|
STATES.hasTouchSupport && getPref(PrefKey.STREAM_TOUCH_CONTROLLER) === "all" && "patchShowSensorControls",
|
||||||
STATES.hasTouchSupport && getPref(PrefKey.STREAM_TOUCH_CONTROLLER) === "all" && "exposeTouchLayoutManager",
|
STATES.hasTouchSupport && getPref(PrefKey.STREAM_TOUCH_CONTROLLER) === "all" && "exposeTouchLayoutManager",
|
||||||
STATES.hasTouchSupport && (getPref(PrefKey.STREAM_TOUCH_CONTROLLER) === "off" || getPref(PrefKey.STREAM_TOUCH_CONTROLLER_AUTO_OFF)) && "disableTakRenderer",
|
STATES.hasTouchSupport && (getPref(PrefKey.STREAM_TOUCH_CONTROLLER) === "off" || getPref(PrefKey.STREAM_TOUCH_CONTROLLER_AUTO_OFF)) && "disableTakRenderer",
|
||||||
|
Loading…
x
Reference in New Issue
Block a user