Mouse click does not trigger event some time on FNCPanel

Hi there,

I hope you are doing well.

We need to trigger a mouse click event on FNCPanel. It seems sometimes that this mouse click event is not triggered. I made a demo to address this issue (attached in this post).

To compare, I counted both mouse down click and mouse click. the counts are supposed to the same. However, if you play with my demo, you will find that sometimes mouse click is not fired.

Any tip for that, thanks!

93. (2.0 MB)

There seems to be some delay and/or timing issue with the panel OnClick detection.
That's what I did with your sample project:

  • First of all, note that you also assigned the Panel's OnClick event to the Form's OnClick event. That's ok for this test.

  • Now please delete the Panel2 OnMouseDown event assignment.

  • Run the project.
    1 - Click any area of the form, and you may last half a second, a second, or more between press&release the mouse button. The Form's OnClick event will always fire, and update the counter.
    2 - Now let's click the Panel.
    If you press the left button and release it very fast, it fires the event.
    If you last a quarter of a second or more to release the button, it won't fire.

    That`s what I got running Delphi 11, Windows 11 & MS Edge.

    Maybe it's a issue to fix for next versions..

We will investigate this here as soon as possible

Thanks Ferrari for the investigation. Yes, Form's Onclick works however I should have deleted this before I tested the Panel's Onclick event. Mouse down click is fired each time but the Mouse click is fired depending on how quickly I release my mouse.

Thanks Pieter. I am looking forward to that.


We have traced and solved this issue in TMS FNC UI Pack. Next version will have this fix included.

Thanks, Pieter!