atlas-engineer / nyxt

Nyxt - the hacker's browser.
https://nyxt-browser.com/
9.64k stars 404 forks source link

Input focus when switching windows #3371

Open aadcg opened 3 months ago

aadcg commented 3 months ago

Commit 3c71755296ebd86fbf124709418c829447766e92 introduced the need to grab the focus of the main buffer (e.g. by clicking it) so that it accepts key events.

To reproduce it, notice that you need to click the main buffer to issue C-space.

aadcg commented 21 hours ago

It is not related to 3c71755296ebd86fbf124709418c829447766e92 and it is, most likely, an Electron bug on Linux.

If it were due to 3c71755296ebd86fbf124709418c829447766e92, then the same would happen on the WebKitGTK port.

The following happens on the Electron port:

Note that on macOS, the bug isn't observed!

Marking it as low since it may be fixed in newer Electron version. The main conclusion here is that this odd behaviour isn't due to our Electron port logic.