mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-11-23 11:59:30 +01:00
fixed finding help for Form properties
git-svn-id: trunk@9753 -
This commit is contained in:
parent
63e2e77804
commit
17e38277d0
@ -1394,18 +1394,24 @@ begin
|
|||||||
if PropertyPath='' then exit;
|
if PropertyPath='' then exit;
|
||||||
BuildTree(false);
|
BuildTree(false);
|
||||||
|
|
||||||
// first search the class in the interface
|
// first search the class/variable in the interface
|
||||||
StartPos:=1;
|
StartPos:=1;
|
||||||
Identifier:=GetNextIdentifier;
|
Identifier:=GetNextIdentifier;
|
||||||
if Identifier='' then exit;
|
if Identifier='' then exit;
|
||||||
Context.Tool:=Self;
|
Context.Tool:=Self;
|
||||||
Context.Node:=FindDeclarationNodeInInterface(Identifier,true);
|
Context.Node:=FindDeclarationNodeInInterface(Identifier,true);
|
||||||
if Context.Node=nil then exit;
|
if Context.Node=nil then begin
|
||||||
Context.Node:=FindTypeNodeOfDefinition(Context.Node);
|
//DebugLn(['TFindDeclarationTool.FindDeclarationOfPropertyPath Identifier not found in interface ',Identifier]);
|
||||||
if Context.Node=nil then exit;
|
exit;
|
||||||
|
end;
|
||||||
Params:=TFindDeclarationParams.Create;
|
Params:=TFindDeclarationParams.Create;
|
||||||
ActivateGlobalWriteLock;
|
ActivateGlobalWriteLock;
|
||||||
try
|
try
|
||||||
|
Context:=FindBaseTypeOfNode(Params,Context.Node);
|
||||||
|
if Context.Node=nil then begin
|
||||||
|
//DebugLn(['TFindDeclarationTool.FindDeclarationOfPropertyPath context not found']);
|
||||||
|
exit;
|
||||||
|
end;
|
||||||
// then search the properties
|
// then search the properties
|
||||||
repeat
|
repeat
|
||||||
//DebugLn('TFindDeclarationTool.FindDeclarationOfPropertyPath ',Context.Node.DescAsString);
|
//DebugLn('TFindDeclarationTool.FindDeclarationOfPropertyPath ',Context.Node.DescAsString);
|
||||||
|
|||||||
@ -249,9 +249,11 @@ begin
|
|||||||
exit;
|
exit;
|
||||||
end;
|
end;
|
||||||
PropPath:=AnInspector.GetActivePropertyGrid.PropertyPath(Row);
|
PropPath:=AnInspector.GetActivePropertyGrid.PropertyPath(Row);
|
||||||
if APersistent is TComponent then
|
if APersistent is TComponent then begin
|
||||||
PropPath:=TComponent(APersistent).Name+'.'+PropPath;
|
PropPath:=TComponent(APersistent).Name+'.'+PropPath;
|
||||||
PropPath:=LookupRoot.ClassName+'.'+PropPath;
|
if TComponent(APersistent).Owner=LookupRoot then
|
||||||
|
PropPath:=LookupRoot.ClassName+'.'+PropPath;
|
||||||
|
end;
|
||||||
// find the property declaration
|
// find the property declaration
|
||||||
if not CodeToolBoss.FindDeclarationOfPropertyPath(Code,PropPath,NewCode,
|
if not CodeToolBoss.FindDeclarationOfPropertyPath(Code,PropPath,NewCode,
|
||||||
NewX,NewY,NewTopLine) then
|
NewX,NewY,NewTopLine) then
|
||||||
@ -261,7 +263,7 @@ begin
|
|||||||
end;
|
end;
|
||||||
Code:=NewCode;
|
Code:=NewCode;
|
||||||
Caret:=Point(NewX,NewY);
|
Caret:=Point(NewX,NewY);
|
||||||
DebugLn('FindDeclarationOfOIProperty SUCCESS ',Code.Filename,' ',dbgs(Caret));
|
//DebugLn('FindDeclarationOfOIProperty SUCCESS ',Code.Filename,' ',dbgs(Caret));
|
||||||
Result:=true;
|
Result:=true;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|||||||
@ -711,7 +711,7 @@ var
|
|||||||
ErrMsg: string;
|
ErrMsg: string;
|
||||||
NewTopLine: integer;
|
NewTopLine: integer;
|
||||||
begin
|
begin
|
||||||
DebugLn('THelpManager.ShowHelpForObjectInspector ',dbgsName(Sender));
|
//DebugLn('THelpManager.ShowHelpForObjectInspector ',dbgsName(Sender));
|
||||||
if Sender=nil then Sender:=ObjectInspector1;
|
if Sender=nil then Sender:=ObjectInspector1;
|
||||||
if Sender is TObjectInspector then begin
|
if Sender is TObjectInspector then begin
|
||||||
AnInspector:=TObjectInspector(Sender);
|
AnInspector:=TObjectInspector(Sender);
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user