message widget didn't really need the symbol expander

This commit is contained in:
Basile Burg 2016-03-21 22:40:33 +01:00
parent 47944eead5
commit 76f63354fa
1 changed files with 10 additions and 15 deletions

View File

@ -105,7 +105,6 @@ type
fToDemangle: TStringList; fToDemangle: TStringList;
fToDemangleObjs: TFPList; fToDemangleObjs: TFPList;
fFiltering: boolean; fFiltering: boolean;
fSymStringExpander: ICESymStringExpander;
function itemShouldBeVisible(item: TTreeNode; aCtxt: TCEAppMessageCtxt): boolean; function itemShouldBeVisible(item: TTreeNode; aCtxt: TCEAppMessageCtxt): boolean;
procedure demanglerOutput(sender: TObject); procedure demanglerOutput(sender: TObject);
procedure filterMessages(aCtxt: TCEAppMessageCtxt); procedure filterMessages(aCtxt: TCEAppMessageCtxt);
@ -261,7 +260,6 @@ var
begin begin
fMaxMessCnt := 500; fMaxMessCnt := 500;
fCtxt := amcAll; fCtxt := amcAll;
fSymStringExpander:= getSymStringExpander;
// //
fActAutoSel := TAction.Create(self); fActAutoSel := TAction.Create(self);
fActAutoSel.Caption := 'Auto select message category'; fActAutoSel.Caption := 'Auto select message category';
@ -978,7 +976,7 @@ end;
function TCEMessagesWidget.guessMessageKind(const aMessg: string): TCEAppMessageKind; function TCEMessagesWidget.guessMessageKind(const aMessg: string): TCEAppMessageKind;
var var
idt: string; idt: string;
rng: TStringRange; rng: TStringRange = (ptr:nil; pos:0; len: 0);
function checkIdent: TCEAppMessageKind; function checkIdent: TCEAppMessageKind;
begin begin
case idt of case idt of
@ -1017,7 +1015,7 @@ end;
function TCEMessagesWidget.getLineFromMessage(const aMessage: string): TPoint; function TCEMessagesWidget.getLineFromMessage(const aMessage: string): TPoint;
var var
rng: TStringRange; rng: TStringRange = (ptr:nil; pos:0; len: 0);
lne: string; lne: string;
col: string = ''; col: string = '';
begin begin
@ -1064,18 +1062,15 @@ begin
getMultiDocHandler.openDocument(absName); getMultiDocHandler.openDocument(absName);
exit(true); exit(true);
end; end;
// if fname relative to native project path or project filed 'root' // if fname relative to project path
absName := expandFilenameEx(fSymStringExpander.expand('<CPP>') + DirectorySeparator, ident); if fProj <> nil then
begin
absName := expandFilenameEx(fProj.filename.extractFileDir + DirectorySeparator, ident);
if absName.fileExists then if absName.fileExists then
begin begin
getMultiDocHandler.openDocument(absName); getMultiDocHandler.openDocument(absName);
exit(true); exit(true);
end; end;
absName := expandFilenameEx(fSymStringExpander.expand('<CPR>') + DirectorySeparator, ident);
if absName.fileExists then
begin
getMultiDocHandler.openDocument(absName);
exit(true);
end; end;
end end
// <assertion failure messg>@<filename> // <assertion failure messg>@<filename>