Sign in Join
FPDoc Onlineexperiment

TCustomDBGrid.MouseButtonAllowed function

Member of TCustomDBGridprotectedIn unit DBGrids

Indicates whether the specified mouse button can be handled when mouse down messages are processed for for the grid control.

Declaration

pascal
function MouseButtonAllowed(Button: TMouseButton): Boolean; override

Arguments

Button

Mouse button checked in the method.

Function result

True if the specified mouse button is handled in the class instance. False if the mouse button is processed by the ancestor class.

Description

MouseButtonAllowed is an overridden method in TCustomDBGrid used to determine whether the specified mouse button can be handled by the grid control. It re-implements the method from the ancestor class, and does not call the inherited method.

The return value is True when the DataLink is Active, and Button contains mbLeft or dgAnyButtonCanSelect has been included in the Options for the control.

MouseButtonAllowed is called when mouse button events are handled in the MouseDown method.

See also

An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.