I am working on a macOS app in which I am using a WKWebview to show web content.
However, after I clicked on another application and then click on my macOS app, I need to click twice on the Webview window, as it doesn't get activated by hovering my mouse over it. It doesn't listen to events until I click the webview window.
I'm new to Swift and being used to Javascript I would just add a 'mouseenter' listener to the macOS window to focus the webview.
Does anybody know how to solve this?
Thanks!