[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] Reference for unit 'Controls' (#lcl)

TDragManager.MouseDown

Performs actions when the drag manager needs to respond to a mouse button down event.

Declaration

Source position: controls.pp line 639

protected procedure TDragManager.MouseDown(

  Button: TMouseButton;

  Shift: TShiftState;

  X: Integer;

  Y: Integer

); virtual; abstract;

Arguments

Button

  

Mouse button for the mouse button down event.

Shift

  

Shift, Ctrl, or Alt modifier for the mouse button down event.

X

  

Horizontal coordinate for the mouse pointer when the button down event occurred.

Y

  

Vertical coordinate for the mouse pointer when the button down event occurred.

Description

MouseDown is an abstract virtual method in TDragManager. It must be overridden in a descendent class to perform actions need for the drag manager implementation.

In the LCL, the drag managers are implementation classes like TDragManagerDefault. This derived classes ignores the button down event in the drag manager to prevent a premature end to a drag operation. The button down event has already been initiated in the message processing loop in TControl. MouseUp handles ending the drag operation.


Version 4.0 Generated 2025-05-03 Home