mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-09 19:35:57 +02:00
codetools: findreferences: when on proc body search proc interface
git-svn-id: trunk@41133 -
This commit is contained in:
parent
d3fc959f04
commit
186067a9f8
@ -1504,6 +1504,15 @@ begin
|
|||||||
else
|
else
|
||||||
NewNode:=CursorNode;
|
NewNode:=CursorNode;
|
||||||
end;
|
end;
|
||||||
|
if (CursorNode.Desc=ctnProcedureHead)
|
||||||
|
and (NodeIsMethodBody(CursorNode.Parent)) then begin
|
||||||
|
// if this is a procedure body, try to find the corresponding declaration
|
||||||
|
NewNode:=FindCorrespondingProcNode(CursorNode.Parent);
|
||||||
|
if (NewNode<>nil) and (NewNode.StartPos<CursorNode.StartPos) then
|
||||||
|
CleanCursorPos:=NewNode.StartPos
|
||||||
|
else
|
||||||
|
NewNode:=CursorNode;
|
||||||
|
end;
|
||||||
|
|
||||||
Result:=JumpToCleanPos(CleanCursorPos,CleanCursorPos,CleanCursorPos,
|
Result:=JumpToCleanPos(CleanCursorPos,CleanCursorPos,CleanCursorPos,
|
||||||
NewPos,NewTopLine,false);
|
NewPos,NewTopLine,false);
|
||||||
|
Loading…
Reference in New Issue
Block a user