The LBUTTON_DN keyboard command acts the
same way as a normal keyboard key. For example if you had used F2
for the above keyboard command you would expect the keyboard
command to execute when you pressed the F2 key no matter where the
mouse cursor was. This is how the LBUTTON_DN key also works.
There are another set of mouse keyboard keys which only execute
when you are on top of the animated object. The key LBUTTON_CMD_DN
will only execute when you press the left mouse button on top of
the animation object which has the keyboard command defined. So to
fix your problem change the LBUTTON_DN to LBUTTON_CMD_DN. There is
also keys for LBUTTON_CMD_UP, RBUTTON_CMD_DN, RBUTTON_CMD_UP.
The raw key codes for this keyboard keys are KEY_LBTN_CMD_DN,
KEY_LBTN_CMD_UP, KEY_RBTN_CMD_DN and KEY_RBTN_CMD_UP.
|