aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/GlobalKeyHandler.ts
diff options
context:
space:
mode:
authorbobzel <zzzman@gmail.com>2024-08-09 16:48:18 -0400
committerbobzel <zzzman@gmail.com>2024-08-09 16:48:18 -0400
commit762ac2bf354e4cc2c4b15f42502da939f5061646 (patch)
tree7c7b2a908d66b08372dbe13956d749b966487ce7 /src/client/views/GlobalKeyHandler.ts
parent4574b7f03ccc85c4bebdbfd9475788456086704f (diff)
a bunch more typing fixes.
Diffstat (limited to 'src/client/views/GlobalKeyHandler.ts')
-rw-r--r--src/client/views/GlobalKeyHandler.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/client/views/GlobalKeyHandler.ts b/src/client/views/GlobalKeyHandler.ts
index 7d01bbabb..a85a03aab 100644
--- a/src/client/views/GlobalKeyHandler.ts
+++ b/src/client/views/GlobalKeyHandler.ts
@@ -56,7 +56,7 @@ export class KeyManager {
window.addEventListener('keydown', KeyManager.Instance.handle);
window.removeEventListener('keyup', KeyManager.Instance.unhandle);
window.addEventListener('keyup', KeyManager.Instance.unhandle);
- window.addEventListener('paste', KeyManager.Instance.paste as any);
+ window.addEventListener('paste', KeyManager.Instance.paste);
}
public unhandle = action((/* e: KeyboardEvent */) => {
@@ -330,7 +330,7 @@ export class KeyManager {
}
break;
case 'c':
- if ((document.activeElement as any)?.type !== 'text' && !AnchorMenu.Instance.Active && DocumentDecorations.Instance.Bounds.r - DocumentDecorations.Instance.Bounds.x > 2) {
+ if (!AnchorMenu.Instance.Active && DocumentDecorations.Instance.Bounds.r - DocumentDecorations.Instance.Bounds.x > 2) {
const bds = DocumentDecorations.Instance.Bounds;
const pt = DocumentView.Selected()[0]
.screenToViewTransform()