kwhat / jnativehook

Global keyboard and mouse listeners for Java.
Other
1.75k stars 348 forks source link

Wayland support #333

Closed J0B10 closed 3 years ago

J0B10 commented 3 years ago

Hey there, first of all thanks for the great work you put into this project!

I'have been using jnativehook to listen for global key inputs and consuming them. On windows it works like a charm! But I probably don't have to tell you that I can't consume events on linux. I read the documentation and found #244 that already covered this topic.

Back then the conclusion was that consuming events with X11 is not possible but with Wayland it could be.
This brought me some hope that maybe we could get support for this in future versions, as most recent linux distros support wayland.

So I'm highly interested what your current plans are regarding Wayland support and consuming key events under linux. Will this be a thing?

J0B10 commented 3 years ago

Nevermind. Just saw that there already is a issue covering that topic. Sorry for the spam.

Duplicate of #211.

kwhat commented 3 years ago

No problem, thanks for checking and closing. I've posted a link to an example project that uses the API we probably want to use on the other ticket. I haven't looked to see if it supports consuming events, but I suspect it does not because of where it resides in the client / server model but there could still be a way. Someones going to have to dig through the docs and just try some things. I am not running Wayland right now and don't expect I will for a while.

J0B10 commented 3 years ago

I'dd be fine with digging through the docs but unfortunately I'm having hard times reading c code on that level and even harder with writing it.