FMX.Platform.TApplicationEventMessage
Delphi
TApplicationEventMessage = class (System.Messaging.TMessage<TApplicationEventData>)
C++
class PASCALIMPLEMENTATION TApplicationEventMessage : public System::Messaging::TMessage__1<TApplicationEventData>
Contents
Properties
Type | Visibility | Source | Unit | Parent |
---|---|---|---|---|
class | public | FMX.Platform.pas FMX.Platform.hpp |
FMX.Platform | FMX.Platform |
Description
Message that contains data about an application event.
This message is sent by the platform-specific implementation of FMX.Platform on the different supported platforms. Application events originate on the underlying system, the system notifies FireMonkey, and FireMonkey sends messages of this type wrapping the system messages.
The contents of the message (TApplicationEventMessage.Value) are of type TApplicationEventData:
- Value.Event indicates the type of the event, such as TApplicationEvent.FinishedLaunching.
- Value.Context is an object that provides additional context. Often the type of event is enough information and Value.Context is null.
Using Events Instead of Messages
Instead of using messages, you can use the SetApplicationEventHandler method of the IFMXApplicationEventService platform service to define an event handler for application events. See When to Use Messages.
Platform Support
FireMonkey only sends this type of message on Android and iOS.
See Also
- System.Messaging (Delphi) code example
- System.Messaging (C++) code example