mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-07-12 18:55:58 +02:00
LCL: reduce calls of PopupMenu property getter. issue #23336
git-svn-id: trunk@39973 -
This commit is contained in:
parent
d2484b1951
commit
28b4ed797c
@ -5624,10 +5624,12 @@ function TWinControl.DoKeyDownBeforeInterface(var Message: TLMKey; IsRecurseCall
|
|||||||
function IsShortCut: Boolean;
|
function IsShortCut: Boolean;
|
||||||
var
|
var
|
||||||
AParent: TWinControl;
|
AParent: TWinControl;
|
||||||
|
APopupMenu: TPopupMenu;
|
||||||
begin
|
begin
|
||||||
Result := False;
|
Result := False;
|
||||||
// check popup menu
|
// check popup menu
|
||||||
if Assigned(PopupMenu) and PopupMenu.IsShortCut(Message) then
|
APopupMenu := PopupMenu;
|
||||||
|
if Assigned(APopupMenu) and APopupMenu.IsShortCut(Message) then
|
||||||
Exit(True);
|
Exit(True);
|
||||||
|
|
||||||
if IsRecurseCall then
|
if IsRecurseCall then
|
||||||
|
Loading…
Reference in New Issue
Block a user