MousePos of TMouseWheelUpDownEvent and TMouseWheelEvent is not relative to Sender if several controls are on one TPanel
- Lazarus/FPC Version: 2.2.0RC1 r65419 FPC 3.2.2
- Operating System: Windows 7
- CPU / Bitness: 64
What happens
MousePos of TMouseWheelUpDownEvent and TMouseWheelEvent is relative to the control over which the mouse is, which is wrong because the event belongs to TPanel. If several controls are on one TPanel, it is impossible to determine to which control the MousePos belongs.
What did you expect
MousePos of TMouseWheelUpDownEvent is relative to Sender (in this case: TPanel).
Steps to reproduce
Create a form with a TPanel and put two TMemo onto the TPanel. Create a handler for OnMouseWheelDown and OnMouseWheelUp. Observe that Sender is the panel but the MousePos is relative to the TMemo over which the mouse is.
Remark
Initially this issue was detected with two TCharts, but it occurs with any controls. The description was edited to get more general attention.