FMX.Types.TCustomGestureCollectionItem.Action

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

property Action: TCustomAction read GetAction write SetAction;

C++

__property Fmx::Actnlist::TCustomAction* Action = {read=GetAction, write=SetAction};

Properties

Type Visibility Source Unit Parent
property public
FMX.Types.pas
FMX.Types.hpp
FMX.Types TCustomGestureCollectionItem

Description

A TAction to be executed when this gesture is recognized.

The Action property is of type TAction and, when assigned, is called when the gesture is recognized. Create the TAction in the usual way, adding a TActionList to the form and populating it with TAction instances.

The alternative to the Action property is to assign the control's OnGesture event. Like the TAction, the OnGesture event handler is called whenever a gesture is recognized. There is only one OnGesture event handler per control, however. The gesture that has been recognized is passed to that event handler. TActions can be assigned per gesture and per control, or can be shared.

See Also