mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: Aug 2003
Posts: 320
P
Pan-dimensional mouse
OP Offline
Pan-dimensional mouse
P
Joined: Aug 2003
Posts: 320
I have a custom picture window with a listbox and a KeyDown remote to handle keystrokes.

When the user presses a cursor movement key (arrow) or space bar a LBClick event fires afterwards.

When the user presses the space key a right click event fires also after that.

How can I stop this from happening?

Whilst on this subject, entering keystrokes for colour codes e.g. Ctrl-B, Ctrl-K causes one or more beeps to occur. Anyone know why or how to stop this?

Many thanks.

Protopia

Joined: Dec 2002
Posts: 1,922
O
Hoopy frood
Offline
Hoopy frood
O
Joined: Dec 2002
Posts: 1,922
See /help $mouse, maybe you'll want to check $mouse.key inside the lbclick and rclick events.

As for the other question I've never heard a beep when pressing Ctrl+K or B, maybe if you disable sounds from the Alt+O > Sound options menu it will stop.

Joined: Aug 2003
Posts: 320
P
Pan-dimensional mouse
OP Offline
Pan-dimensional mouse
P
Joined: Aug 2003
Posts: 320
Thanks for the pointer - but $mouse.key os always 0 for lbclick events.

Stopping sounds using options is a little heavy handed.

I have found a workaround to ignore the rclicks and lbclicks within 1ms of a keystroke.

Currently working on a way to reset the selected items if selected during this period.

Thanks for the interest.

Protopia

Joined: Dec 2002
Posts: 1,922
O
Hoopy frood
Offline
Hoopy frood
O
Joined: Dec 2002
Posts: 1,922
You're right, $mouse.key has no value there. Here's a way to keep the current selection when the up/down keys are pressed:
Code:
On *:keydown:@window:38,40:{
  .timer 1 0 sline $active $$sline($active,1).ln
}


Link Copied to Clipboard