wkwebview: move keyDown handler to WindowController so it doesn't require a click to activate

This commit is contained in:
Thomas Weber committed 2025-01-18 12:31:22 -06:00
1 parent 4e7e061176
commit 0d563fa3ba
2 files changed
+4 -4

No files matched your search

-4
View File
@@ -136,8 +136,4 @@ class ViewController: NSViewController, WKNavigationDelegate, WKUIDelegate, WKSc
// Implements window.close()
self.view.window?.close();
}
override func keyDown(with event: NSEvent) {
// Don't call super.keyDown so that it won't play the beeping noise.
}
}
+4
View File
@@ -5,4 +5,8 @@ class WindowController : NSWindowController {
super.init(coder: coder)
shouldCascadeWindows = true
}
override func keyDown(with event: NSEvent) {
// Don't call super.keyDown so that it won't play the beeping noise.
}
}