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

TControl.DoMouseWheel

Signals the OnMouseWheel handlers, when the mouse wheel has been turned.

Declaration

Source position: controls.pp line 1542

protected function TControl.DoMouseWheel(

  Shift: TShiftState;

  WheelDelta: Integer;

  MousePos: TPoint

):Boolean; virtual;

Arguments

Shift

  

State of the modifier keys and mouse buttons.

WheelDelta

  

How many notches the wheel has been turned.

MousePos

  

The mouse coordinates.

Function result

Set Result to True if handled.

Description

Multiple wheel handlers can be implemented. First the general OnMouseWheel handler is tried, and if it doesn't report the event handled, then OnMouseWheelUp or OnMouseWheelDown are tried.

The actual WheelDelta is available only to the OnMouseWheel handler, not to the up and down handlers [Delphi compatible].

See also

TMouseWheelEvent

  

Specifies an event handler used to respond to mouse wheel events.

TMouseWheelUpDownEvent

  

Type of OnMouseWheelUp/Down event handlers.


Version 3.2 Generated 2024-02-25 Home