mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-11 17:16:01 +02:00
codetools: identifier completion+events: fixed collecting helpers, patch #28794
git-svn-id: trunk@49982 -
This commit is contained in:
parent
9c1c655448
commit
7eec3d4b45
@ -4986,7 +4986,7 @@ procedure TFindDeclarationTool.FindHelpersInContext(
|
||||
var
|
||||
Node: TCodeTreeNode;
|
||||
begin
|
||||
Node:=Params.StartNode;
|
||||
Node:=Params.ContextNode;
|
||||
Params.FNeedHelpers:=false;
|
||||
while Node<>nil do
|
||||
begin
|
||||
@ -12193,9 +12193,16 @@ end;
|
||||
|
||||
function TFindDeclarationParams.GetHelpers(HelperKind: TFDHelpersListKind;
|
||||
CreateIfNotExists: boolean): TFDHelpersList;
|
||||
var
|
||||
xLastContextNode: TCodeTreeNode;
|
||||
begin
|
||||
if FNeedHelpers then
|
||||
begin
|
||||
xLastContextNode:=ContextNode;
|
||||
ContextNode:=StartNode;
|
||||
StartTool.FindHelpersInContext(Self); // beware: this calls GetHelpers
|
||||
ContextNode:=xLastContextNode;
|
||||
end;
|
||||
Result:=FHelpers[HelperKind];
|
||||
if (Result=nil) and CreateIfNotExists then begin
|
||||
Result:=TFDHelpersList.Create(HelperKind);
|
||||
|
Loading…
Reference in New Issue
Block a user