[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] |
Signals an OnActionUpdate handler (when assigned).
Source position: forms.pp line 1613
public function TApplication.UpdateAction( |
TheAction: TBasicAction |
):Boolean; override; |
TheAction |
|
The action updated in an event handler. |
True if the action was updated in the event handler.
UpdateAction is an overridden Boolean function used to signal an OnActionUpdate event handler (when assigned) to update the settings in the action instance in TheAction. UpdateAction reimplements the method defined in the ancestor (TComponent), and does not call the inherited method.
UpdateAction signals a TActionEvent event handler using the action instance in TheAction as an argument. The Handled argument in the event is used as the return value for the method, and is set to True if the action was successfully updated in an event handler.
In LCL version 3.0 or higher, multiple handler routines can be assigned which use the ahtActionUpdate event type. This situation can occur when TApplicationProperties tries to assign an OnActionUpdate handler to the TApplication instance and it already has a user-specified handler. It can also happen when the AddOnActionUpdateHandler method is called directly to add a handler routine for the application event type.
If OnActionUpdate handler is not assigned, or returns False, the other handlers in the internal list are signalled to determine whether they can update the action. Each handler routine is signalled until one of them changes the Handled argument in the event type to True. If none of the routines can update the action, the return value is False.
Modified in in LCL version 3.0 to provide support for multiple OnActionUpdate event handlers in the application.
|
Adds the specified routine to the list of ahtActionUpdate handlers for the application. |
|
|
Removes the specified routine from the list of ahtActionUpdate handlers for the application. |
|
|
Types of Application notification handlers. |
|
|
Specifies an event handler signalled to implement an action in TCustomActionList. |
|
Version 3.2 | Generated 2024-02-25 | Home |