-
Notifications
You must be signed in to change notification settings - Fork 76
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
Fix osx modifier keys after restart #190
Fix osx modifier keys after restart #190
Conversation
I tried this PR today with the latest master commit (5a34841) and I can confirmed it fixed the issue with my K95 RGB. Mac Specs: Please let me know if you require any addition information that would help complete this PR. |
Does this survive logout events/system suspend? |
Working perfectly for me on Sierra 10.12.4 if I restart the iMac but stops working after closing the session and logging in again |
@tatokis, @smachi the daemons launched by root appears to doesn't stop when the user logout on macOS, just stay running. I didn't found an easy way to check if the user logged out and logged in again. I've found a workaround, create a /tmp/ckb file with the PID of the ckb.app (from the ckb.app that stops when the user logs out) From the daemon I've created a timer that check if the PID has been changed every 5s and if changed, the daemon invalidate the mouse_event_tap and create a new one. As I said I have no idea of C, so maybe someone can found a better solution. |
My Hackintosh has self-annihilated, so I cannot test this in the nearest month or two, sorry, so I cannot leave a direct approvement. Nevertheless, this will be merged sooner or later as soon as someone else shares his experience. Thank you for the contribution! |
As someone who is affected by this issue, I would like to see this fix in a release fairly soon. I have the following setup: Macbook Pro 15" (mid 2015) With the current release version (0.28), using Shift to select multiple files in Mac OS Finder does not work. With the build from this PR, it works, and continues to work after both a ckb restart and a system restart. I hope this helps somewhat. |
Restarting the daemon fixes the issue for Cmd and Shift, but the Option button as modifier still doesn't work. |
Merged to master |
How i do this? "restart the daemon" ? can someone explain me? tnks |
Hey @AlfaceVerde do the following:
It will auto respawn and you modifier keys should start working as expected again. |
First try to fix the #29.
The issue appears to was solved on a previous PR but the problems appears again after restart. The problem was that CGEventTapCreate needs that the windows server are running to create the event.
I don't know nothing about C but I added a while loop until the mouse_event_tap was created and added to the run_loop and it works for me.
Regards!