-
Notifications
You must be signed in to change notification settings - Fork 290
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support Electron 9, 10 and 11 #258
Conversation
Hey @ykhwong, Thanks for all this work, this is awesome. Thanks |
Allright, I've removed cmake-js, added fs-extra dev dependency on my local machine. Can't push on your branch. Now, I have this error: Any idea ? |
The error occurred because node-gyp could not handle symbolic .gyp links properly on Linux and macOS. I fixed the issue by copying the gyp files manually. Encountered another weird error on travis-ci though: |
I assumed that rpath does not get resolved properly, so instructed the node-gyp to get the correct path of the iohook module. Could you try again with the last commit, please? Here are commands that I executed for testing: node-v10 on Ubuntu x64
electron-v9.0.0 on Ubuntu x64
|
Any update on this? I've been digging around the web for any solution to electron + iohook (build documentation is poor) without going back too far in electron versions |
Hey, I didn't have time to re-test everything. Last time I did, I was not able to have the same result. If anyone wants to help, we need to validate the author's change before merging and releasing a new version. |
Hello, I took a stab at some testing tonight building on macOS 10.13 and Windows 10 and had (mostly) success with Electron 9: (also made a new Electron example demo app for testing which I found helpful, it uses iohook directly in the renderer process which has several advantages, in case you want to try it I submitted a pr #265) Some issues I observed:
|
Update: Tested on Mac today with a full size generic USB keyboard. The following keys are not firing keydown events (but as noted above are producing logging output in the Node console): all F-keys, down arrow, insert, home, end, pgup, pgdown. So not exactly the same keys not working in Windows with this build. |
@marcelblum , @Djiit Yes . I test in Windows 10 and Electron 11.0.3 |
Oh it works for 11 as well? That's sweet! |
Just realized why those random keys weren't firing events - it was because the stale examples folder demos I was testing with use the deprecated |
And yeah I also tried compiling with an electron 11 (abi 85) target and it totally works: Awesome work by @ykhwong ! |
And I'm an idiot, the only reason for the verbose logging I was complaining about is because the examples use |
This is exciting! I really need this for electron 10, if I can help in any way let me know. sign me up for the alpha test, or whatever is needed. I am not familiar enough with the project to help much with the code. But I believe in you guys! 👏 |
ok . you can clone this project and build for your abi eg in electron 11.0.3 is abi is 85 |
I was able to reproduce everything (node 14, electron 9 and 11) locally. Thanks @ykhwong for this awesome work. I'll merge this and work on a release. |
So, build is working, but the prebuilt are now. If anyone wants to help. I'm creating an issue. |
Description
Build iohook for electron 9 and 10
Motivation and Context
For details, please refer to #241