fixed source editor breakpoint set/unset and codefolding

git-svn-id: trunk@7992 -
This commit is contained in:
mattias 2005-10-28 06:26:15 +00:00
parent 0d278e2ad3
commit 475bacd9a9
2 changed files with 12 additions and 8 deletions

View File

@ -2519,9 +2519,10 @@ begin
break;
end;
end;
end; //for
end;
end;
if Assigned(fOnGutterClick) then begin
// for compatibility invoke this only on the markable area
fOnGutterClick(Self, X, Y, line, mark);
end;
end;

View File

@ -1738,13 +1738,16 @@ procedure TSourceEditor.OnGutterClick(Sender: TObject; X, Y, Line: integer;
var
BreakPtMark: TSourceMark;
begin
// create or delete breakpoint
// find breakpoint mark at line
BreakPtMark := SourceEditorMarks.FindBreakPointMark(FEditor,Line);
if BreakPtMark = nil then
DebugBoss.DoCreateBreakPoint(Filename,Line)
else
DebugBoss.DoDeleteBreakPointAtMark(BreakPtMark);
if (not EditorComponent.Gutter.ShowCodeFolding)
or (X>=EditorComponent.Gutter.CodeFoldingWidth) then begin
// create or delete breakpoint
// find breakpoint mark at line
BreakPtMark := SourceEditorMarks.FindBreakPointMark(FEditor,Line);
if BreakPtMark = nil then
DebugBoss.DoCreateBreakPoint(Filename,Line)
else
DebugBoss.DoDeleteBreakPointAtMark(BreakPtMark);
end;
end;
procedure TSourceEditor.OnEditorSpecialLineColor(Sender: TObject; Line: integer;