RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
Controls.TMouseEvent Type

TMouseEvent is the function type for either an OnMouseDown event or an OnMouseUp event.

Pascal
TMouseEvent = procedure (Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer) of object;
C++
(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer) ( TMouseEvent)();

TMouseEvent has the following parameters:

Parameter 
Meaning 
Sender  
The control that generated the event.  
Button  
The mouse button that is pressed. This parameter can have one of the following values: mbLeft, mbRight, mbMiddle.  
Shift  
The state of the Alt, Ctrl, Shift keys, and the mouse buttons.  
X  
The current X coordinate of the mouse cursor.  
X  
The current Y coordinate of the mouse cursor.  

 

Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!