I am new to c# .NET Compact Framework 3.5.
I am trying to prevent mouse events from eager users to queue up. This sometimes leads to unintended clicks.
What is the best way to ignore queued mouse messages on the .NET Compact Framework platform? Sadly, the code has to run on the UI thread.
I have tried: 1. Disable window and Application.DoEvents(); then Enabled window --> it did not work. 2. I read a lot about PeekMessage() --> but could not figure out.
please recommend me resource which i can learn.
Thank you so much.
Something like this
class MyForm : Form
{
private bool _processing;
private void OnMousedown(....) // really depends on what you use,
// Click/doubleclick/Up/down - concept is the same
{
if (_processing)
return;
_processing = true;
// do something
. . . . . .
_processing = false;
}
. . . . .
you may need to do it on each control event