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

# TCustomGrid.GridMouseWheel

Performs actions to apply a mouse wheel message to the grid control.

## Declaration

Source position: grids.pas line 1126

`protected procedure TCustomGrid.GridMouseWheel(`
`Shift: TShiftState;`
`Delta: Integer`
`); virtual;`

## Arguments

`Shift` |  | Shift state modifier in effect for the action.
`Delta` |  | Relative change in the current position for the action.

## Description

GridMouseWheel ensures that the Delta value for the mouse wheel event is correctly applied for horizontal scroll messages. These are the scroll messages which occurs when the Ctrl key is pressed. GridMouseWheel calls the MoveNextSelectable for both horizontal and vertical messages, but the value in Delta is used as the column argument when Ctrl is included in the Shift modifier. Otherwise, Delta is used as the Row argument.

GridMouseWheel is called from methods like: DoMouseWheelDown, DoMouseWheelUp, DoMouseWheelLeft, and DoMouseWheelRight.

## See also

TCustomGrid.MoveNextSelectable |  | Moves to the next selectable cell in the specified direction.
TCustomGrid.DoMouseWheelDown |  | Handles a mouse wheel down movement for the grid control.
TCustomGrid.DoMouseWheelUp |  | Handles a mouse wheel up movement for the grid control.
TCustomGrid.DoMouseWheelLeft |  | Handles a mouse wheel scroll left message for the control.
TCustomGrid.DoMouseWheelRight |  | Handles a mouse wheel scroll right message for the control.