Show: Delphi C++
Display Preferences


From RAD Studio API Documentation
Jump to: navigation, search



TCustomAction = class(TContainedAction)


class PASCALIMPLEMENTATION TCustomAction : public System::Actions::TContainedAction


Type Visibility Source Unit Parent
class public
FMX.ActnList FMX.ActnList


TCustomAction is the base class for FireMonkey actions intended to be used with menu items and controls.

TCustomAction introduces support for the properties, events, and methods of menu items and controls that are clients of actions.

Most properties and events introduced in TCustomAction are public; therefore, use TCustomAction as a base class when deriving your own actions that publish specific subset of properties of associated controls.

Actions centralize responses to user commands (user actions). An action is associated to user interface elements (components) in an application that use this action. Actions provide an easy way to synchronize values of properties of an action and of associated components (clients), for example, the enabled state and caption of an action and of an associated speed button and a menu item, and handle the response when the user clicks these components. Each such component, called the client, has its properties dynamically updated by the associated action and forwards user commands to the action for a response.

The Text property can be used to set an accelerator key to the action. Notice that & and _ are seen and can be used only under Windows.

At design time, you can work in the Action List editor with actions contained in an action list. The action list is a container for actions, which it organizes into categories (File, Edit, and others).

Component and control public properties and events that are supported in TCustomAction, either directly or through an ancestor, are:

TCustomAction is the base class for TAction and TCustomViewAction.

TCustomAction acts as the base class for several predefined action classes. For predefined actions that augment the behavior of TCustomAction, see the action classes in the FMX.StdActns unit.

Code Examples

See Also

Personal tools
In Other Languages
Previous Versions