From 2cab29d82bcc531a23628a12f7a96cac7ebf1581 Mon Sep 17 00:00:00 2001 From: juha Date: Mon, 26 Dec 2011 15:20:05 +0000 Subject: [PATCH] LeakView: formatting git-svn-id: trunk@34433 - --- components/leakview/heaptrcview.pas | 19 ++++++++++++------- 1 file changed, 12 insertions(+), 7 deletions(-) diff --git a/components/leakview/heaptrcview.pas b/components/leakview/heaptrcview.pas index 52c6a36f0c..b613a9b35a 100644 --- a/components/leakview/heaptrcview.pas +++ b/components/leakview/heaptrcview.pas @@ -97,10 +97,12 @@ implementation procedure ShowHeapTrcViewForm(JumpProc: TJumpProc); begin - if not Assigned(HeapTrcViewForm) then HeapTrcViewForm := THeapTrcViewForm.Create(Application); - if not Assigned(JumpProc) - then HeapTrcViewForm.OnJumpProc := @HeapTrcViewForm.LazarusJump - else HeapTrcViewForm.OnJumpProc := JumpProc; + if not Assigned(HeapTrcViewForm) then + HeapTrcViewForm := THeapTrcViewForm.Create(Application); + if Assigned(JumpProc) then + HeapTrcViewForm.OnJumpProc := JumpProc + else + HeapTrcViewForm.OnJumpProc := @HeapTrcViewForm.LazarusJump; HeapTrcViewForm.Show; end; @@ -275,7 +277,8 @@ procedure THeapTrcViewForm.ClearItems; var i : integer; begin - for i := 0 to fItems.Count - 1 do TObject(fItems[i]).Free; + for i := 0 to fItems.Count - 1 do + TObject(fItems[i]).Free; fItems.Clear; end; @@ -385,7 +388,8 @@ end; function THeapTrcViewForm.GetStackLineText(const Line: TStackLine; useRaw: boolean): string; begin - if useRaw then Result := Line.RawLineData; + if useRaw then + Result := Line.RawLineData; if not useRaw or (Result = '') then with Line do if FileName <> '' @@ -499,7 +503,8 @@ var begin if not FileExistsUTF8(SourceFile) then begin nm := LazarusIDE.FindSourceFile(SourceFile, '', [fsfUseIncludePaths] ); - if nm = '' then nm := SourceFile; + if nm = '' then + nm := SourceFile; end else nm := SourceFile; LazarusIDE.DoOpenFileAndJumpToPos(nm, Point(1, Line), -1, -1, -1, [ofOnlyIfExists, ofRegularFile]);