galaktor / gostwriter

A virtual keyboard for linux, which makes use of /dev/uinput to inject key events.
GNU General Public License v3.0
24 stars 7 forks source link

Add button presses as possible events #7

Closed idupree closed 8 years ago

idupree commented 8 years ago

This lets you synthesize a mouse click using key.CODE_BTN_LEFT. Or other mouse-buttons with other CODE_BTN_*.

If you prefer a different naming, that is possible. I couldn't name it key.CODE_LEFT because that is already taken by the left-arrow key. key.BTN_LEFT would be fine, though I figured you have something against that naming pattern since it's not key.KEY_3 for the 3 key. (did the preprocessor interfere?)

I can rebase the last two commits if you want an extra-clean commit history.

galaktor commented 8 years ago

Hi! Thanks for contributing - I'll have a closer look soon! Cheers

galaktor commented 8 years ago

HI @idupree I like your changes, particularly

I'm in favour of them all and your work looks good to me. It looks like there's some overlap between the three pull requests (unless I'm mistaken; I only had a quick look). It would be awesome if you could collect your changes in a single PR after rebasing (as you suggested) and I'll pull it in.

Again, thanks a ton for contributing, much appreciated that you're going that extra mile!

idupree commented 8 years ago

@galaktor This pull request depends on all the others, so all you need to do is merge this one.

For more work: I'd like to add some mouse movement events, but I'm not as sure where to start for that. Do you have thoughts?

galaktor commented 8 years ago

@idupree I would have to dig into that question, but I wonder what the linux kernel exposes for you to detect movement events in the first place?

PS sorry for the delay in accepting your PR, I was travelling for a while and didn't get a chance until today. Thanks for the support!

idupree commented 8 years ago

@galaktor Since this is closed now, moving discussion to https://github.com/galaktor/gostwriter/issues/8