From 54af11a069b41488357327df8c856fed77e95bbd Mon Sep 17 00:00:00 2001 From: mattias Date: Thu, 7 Jul 2016 23:34:45 +0000 Subject: [PATCH] codetools: identifier completion: method specifiers git-svn-id: trunk@52647 - --- components/codetools/identcompletiontool.pas | 25 ++++++++++---------- 1 file changed, 13 insertions(+), 12 deletions(-) diff --git a/components/codetools/identcompletiontool.pas b/components/codetools/identcompletiontool.pas index 324b37229d..17d5ee1bfe 100644 --- a/components/codetools/identcompletiontool.pas +++ b/components/codetools/identcompletiontool.pas @@ -1950,18 +1950,19 @@ begin if NodeInFront<>nil then begin if NodeInFront.Desc=ctnProcedureHead then begin // procedure head postfix modifiers - case Node.Desc of - ctnClass,ctnObject,ctnObjCCategory,ctnObjCClass, - ctnClassHelper, ctnRecordHelper, ctnTypeHelper, - ctnClassPrivate,ctnClassProtected,ctnClassPublic,ctnClassPublished: - AddMethodSpecifiers; - else - //debugln(['TIdentCompletionTool.GatherContextKeywords ',NodeInFront.Parent.DescAsString]); - if NodeInFront.Parent.Desc=ctnProcedure then - AddProcSpecifiers - else if NodeInFront.Parent.Desc=ctnProcedureType then - AddProcTypeSpecifiers; - end; + //debugln(['TIdentCompletionTool.GatherContextKeywords NodeInFront.Parent=',NodeInFront.Parent.DescAsString]); + if NodeInFront.Parent.Desc=ctnProcedure then begin + //debugln(['TIdentCompletionTool.GatherContextKeywords NodeInFront.Parent.Parent=',NodeInFront.Parent.Parent.DescAsString]); + case NodeInFront.Parent.Parent.Desc of + ctnClass,ctnObject,ctnObjCCategory,ctnObjCClass, + ctnClassHelper, ctnRecordHelper, ctnTypeHelper, + ctnClassPrivate,ctnClassProtected,ctnClassPublic,ctnClassPublished: + AddMethodSpecifiers; + else + AddProcSpecifiers; + end; + end else if NodeInFront.Parent.Desc=ctnProcedureType then + AddProcTypeSpecifiers; end; end; except