When applied to the Manage icon, such as long press the show delete flag, click Cancel to remove the flag.
In the FMX gesture management, only long press LONGTAP, tap Tap is a separate event and cannot be managed in the same event.
After executing the LONGTAP, tap will also be triggered?, the solution, to determine whether long press and click the same position:
Add variable
Taploaction:tpointf??;
Procedure Tform1.form1gesture (Sender:tobject; Const Eventinfo:tgestureeventinfo; var handled:boolean);?
Begin
Case Eventinfo.gestureid of
Igilongtap:begin?
Taplocation:= eventinfo.location;?
{Execute Longtap}
End;?
End;?
End;???
Procedure Tform1.form1tap (sender:tobject; const point:tpointf);
Begin?
If Point<>taplocation then begin?
taplocation.x:=0;?
taplocation.y:=0;?
{Execute tap}
End;?
End;??
After testing, it was found that more desirable results,
Also need to add a timer to set the time interval,
In the Ontap event, whether or not the time interval is exceeded to respond,
Avoid long presses and respond when you let go.
DELPHI FMX uses both Longtap and tap