mirror of
https://github.com/redphx/better-xcloud.git
synced 2025-06-06 15:47:18 +02:00
Only show toast when the layout has been changed
This commit is contained in:
parent
a878150ec3
commit
6b090194c9
@ -3553,6 +3553,8 @@ class TouchController {
|
||||
return;
|
||||
}
|
||||
|
||||
const layoutChanged = TouchController.#currentLayoutId !== layoutId;
|
||||
|
||||
TouchController.#currentLayoutId = layoutId;
|
||||
xboxTitleId = '' + xboxTitleId;
|
||||
|
||||
@ -3566,7 +3568,7 @@ class TouchController {
|
||||
const layout = (layoutData.layouts[layoutId] || layoutData.layouts[layoutData.default_layout]);
|
||||
if (layout) {
|
||||
// Show a toast with layout's name
|
||||
Toast.show(__('touch-control-layout'), layout.name);
|
||||
layoutChanged && Toast.show(__('touch-control-layout'), layout.name);
|
||||
|
||||
setTimeout(() => {
|
||||
window.BX_EXPOSED.touch_layout_manager.changeLayoutForScope({
|
||||
|
Loading…
x
Reference in New Issue
Block a user