关于FMX 单击出来右键菜单,并显示在当前下面
作者:互联网
关于FMX 单击出来右键菜单,并显示在当前下面
procedure TForm1.btn6MouseDown(Sender: TObject; Button: TMouseButton;
Shift: TShiftState; X, Y: Single);
var
LP: TPointF;
begin
LP := btn6.LocalToAbsolute(TPointF.Create(btn6.Width / 2, btn6.Height / 2 ));
LP := btn6.Scene.LocalToScreen(lP);
btn6.PopupMenu.PopupComponent := btn6;
btn6.PopupMenu.Popup(Round(LP.X), Round(LP.Y));
end;
标签:TPointF,FMX,单击,右键,LP,btn6 来源: https://www.cnblogs.com/pykill/p/11326526.html