Fix errors with setTimeout/setInterval

This commit is contained in:
redphx
2024-04-25 17:46:02 +07:00
parent 9b9a7d2bf2
commit 53676ad733
16 changed files with 30 additions and 30 deletions

View File

@@ -151,7 +151,7 @@ export class MkbRemapper {
this.#clearEventListeners();
this.#bindKey(this.#$.currentBindingKey!, KeyHelper.getKeyFromEvent(e));
setTimeout(() => this.bindingDialog.hide(), 200);
window.setTimeout(() => this.bindingDialog.hide(), 200);
};
#onMouseDown = (e: MouseEvent) => {
@@ -159,7 +159,7 @@ export class MkbRemapper {
this.#clearEventListeners();
this.#bindKey(this.#$.currentBindingKey!, KeyHelper.getKeyFromEvent(e));
setTimeout(() => this.bindingDialog.hide(), 200);
window.setTimeout(() => this.bindingDialog.hide(), 200);
};
#onKeyDown = (e: KeyboardEvent) => {
@@ -171,7 +171,7 @@ export class MkbRemapper {
this.#bindKey(this.#$.currentBindingKey!, KeyHelper.getKeyFromEvent(e));
}
setTimeout(() => this.bindingDialog.hide(), 200);
window.setTimeout(() => this.bindingDialog.hide(), 200);
};
#onBindingKey = (e: MouseEvent) => {