I try use this deiphi code: http://delphifmandroid.blogspot.com/201 ... droid.html
- Code: Select all
public: // User declarations
bool __fastcall HandleAppEvent(TApplicationEvent *AAppEvent, TObject *AContext);
//***
void __fastcall TForm1::FormCreate(TObject *Sender)
{
IFMXApplicationEventService *aFMXApplicationEventService;
if (TPlatformServices::Current->SupportsPlatformService(__uuidof(IFMXApplicationEventService), _di_IInterface(aFMXApplicationEventService)))
aFMXApplicationEventService->SetApplicationEventHandler(HandleAppEvent);//<- ettor
}
[bccaarm Error] UnitMikros.cpp(330): cannot initialize a parameter of type 'TApplicationEventHandler' (aka 'bool (__closure *)(Fmx::Platform::TApplicationEvent, __borland_class *System::TObject __strong) __attribute__((pcs("aapcs-vfp")))') with an lvalue of type 'bool (__closure *)(Fmx::Platform::TApplicationEvent *, __borland_class *System::TObject __strong) __attribute__((pcs("aapcs-vfp")))'
FMX.Platform.hpp(256): passing argument to parameter 'AEventHandler' here
How fix?