autokbisw icon indicating copy to clipboard operation
autokbisw copied to clipboard

Triggered by mouse?

Open sjonez opened this issue 6 years ago • 2 comments

Great little tool for my MBP for correcting the layout of my USB keyboard when it's plugged in, however I also have a logitech USB mouse and autokbisw also seems to be assigning a keyboard layout to that whenever I click!

Here's a log of my typing on both my keyboards and clicking my mouse:

starting with useLocation:false - verbosity:1 set input source to <TSMInputSource 0x7f9f35003740> KB Layout: British - PC (id=250) for keyboard Optional(Dell USB Keyboard)-[Optional(16700)-Optional(8195)-Optional(Dell)-nil] set input source to <TSMInputSource 0x7f9f35002fa0> KB Layout: British (id=2) for keyboard Optional(Apple Internal Keyboard / Trackpad)-[Optional(1452)-Optional(635)-Optional(Apple Inc.)-Optional(FM783050239J3VYAX+RCP)] set input source to <TSMInputSource 0x7f9f35003740> KB Layout: British - PC (id=250) for keyboard Optional(Dell USB Keyboard)-[Optional(16700)-Optional(8195)-Optional(Dell)-nil] set input source to <TSMInputSource 0x7f9f35003740> KB Layout: British - PC (id=250) for keyboard Optional(Gaming Mouse G402)-[Optional(1133)-Optional(49278)-Optional(Logitech)-Optional(6D93279B5255)]

Is there any way to exclude the mouse from having its own layout?

sjonez avatar Sep 12 '18 11:09 sjonez

it seems the Logitech G402 mouse is being seen by OSX as also being a keyboard (perhaps due to the additional buttons?) so this is not so much a bug in autokbisw, but it would be good if I could exclude/ignore it.

sjonez avatar Sep 12 '18 11:09 sjonez

hello, sorry I haven't been able to come back to this.

There is no way to exclude the mouse if it reports itself as a keyboard at this time. I have thought about this a bit and I am unsure how to proceed.

The easiest option would be to add a repeatable -e/--exclude command line parameter allowing to specify inputsource id(s) to be excluded from the layout management. what do you think ?

jeantil avatar Oct 16 '18 15:10 jeantil