From d868b219ae7c524fae4ab5b6fa318b55f7228ffb Mon Sep 17 00:00:00 2001 From: mattias Date: Mon, 9 Feb 2015 16:38:53 +0000 Subject: [PATCH] IDE: fpc msg parser: improve cant find unit when an indirectly used unit has no ppu in project and package git-svn-id: trunk@47656 - --- components/ideintf/ideexterntoolintf.pas | 14 +++++++++----- ide/etfpcmsgparser.pas | 10 +++++++++- ide/findunitdlg.pas | 6 ++++-- 3 files changed, 22 insertions(+), 8 deletions(-) diff --git a/components/ideintf/ideexterntoolintf.pas b/components/ideintf/ideexterntoolintf.pas index ae69d3cfdd..a7de975798 100644 --- a/components/ideintf/ideexterntoolintf.pas +++ b/components/ideintf/ideexterntoolintf.pas @@ -2188,14 +2188,18 @@ end; function TMessageLine.GetToolData: TIDEExternalToolData; var - View: TExtToolView; + Tool: TAbstractExternalTool; begin Result:=nil; if Lines=nil then exit; - View:=TExtToolView(Lines.Owner); - if not (View is TExtToolView) then exit; - if View.Tool=nil then exit; - Result:=TIDEExternalToolData(View.Tool.Data); + if Lines.Owner is TAbstractExternalTool then + Tool:=TAbstractExternalTool(Lines.Owner) + else if Lines.Owner is TExtToolView then begin + Tool:=TExtToolView(Lines.Owner).Tool; + if Tool=nil then exit; + end else + exit; + Result:=TIDEExternalToolData(Tool.Data); if not (Result is TIDEExternalToolData) then Result:=nil; end; diff --git a/ide/etfpcmsgparser.pas b/ide/etfpcmsgparser.pas index 8f1e428168..f8ba5944ad 100644 --- a/ide/etfpcmsgparser.pas +++ b/ide/etfpcmsgparser.pas @@ -1796,6 +1796,7 @@ var i: Integer; DepOwner: TObject; PkgFile: TLazPackageFile; + TheOwner: TObject; begin if MsgLine.Urgency