Mouse button

Announcements, questions
Post Reply
Bahamut
Posts: 1
Joined: 05 Apr 2016, 19:04

Mouse button

Post by Bahamut » 05 Apr 2016, 19:22

Hi i'm a beginner whit this program. I would to remap a side button of mouse, bound to "left control". With lmc_print_devices() return that the mouse is detected like keyboard. I can set the button to "K" for example and it worked but is also pressed the "L Ctrl". My target is to have the "K" but no the "L Ctrl".

My lua:
-- assign logical name to macro keyboard
lmc_assign_keyboard('MACROS');

-- define callback for whole device
lmc_set_handler('MACROS',function(button, direction)
if (button == 17) then lmc_send_keys ("K")
end
end)

Any help?

Ps: Sorry for my bad english

admin
Site Admin
Posts: 735
Joined: 01 Nov 2010, 13:00
Location: Prague, Czech republic
Contact:

Re: Mouse button

Post by admin » 06 Apr 2016, 08:07

Your mouse driver simulating keyboard is probably kind of special.
I'm not even sure if you can remap single Ctrl at regular keyboard - you can try.
Anyway if LuaMacros is not blocking the control key from your mouse I think the API hack inside LuaMacros just doesn't work for your mouse driver. The script is correct, keys should be blocked for whole device.
Petr Medek
LUAmacros author

Post Reply