mirror of
https://github.com/redphx/better-xcloud.git
synced 2025-06-06 23:57:19 +02:00
Show confirm dialog to refresh the stream after holding for 1s
This commit is contained in:
parent
4b0f0784ae
commit
889717be7d
@ -1835,7 +1835,8 @@ function injectVideoSettingsButton() {
|
||||
isHolding = false;
|
||||
holdTimeout = setTimeout(() => {
|
||||
isHolding = true;
|
||||
}, 750);
|
||||
confirm('Do you want to refresh the stream?') && window.location.reload();
|
||||
}, 1000);
|
||||
};
|
||||
const onMouseUp = e => {
|
||||
holdTimeout && clearTimeout(holdTimeout);
|
||||
@ -1843,7 +1844,6 @@ function injectVideoSettingsButton() {
|
||||
if (isHolding) {
|
||||
e.preventDefault();
|
||||
e.stopPropagation();
|
||||
confirm('Do you want to refresh the stream?') && window.location.reload();
|
||||
}
|
||||
isHolding = false;
|
||||
};
|
||||
|
Loading…
x
Reference in New Issue
Block a user