mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-09-28 08:09:16 +02:00
IDE: find start of code block: add jump point
git-svn-id: trunk@34904 -
This commit is contained in:
parent
7ecfbd3e9e
commit
3c697b0983
@ -15685,6 +15685,7 @@ var ActiveSrcEdit: TSourceEditor;
|
||||
ActiveUnitInfo: TUnitInfo;
|
||||
NewSource: TCodeBuffer;
|
||||
NewX, NewY, NewTopLine: integer;
|
||||
Flags: TJumpToCodePosFlags;
|
||||
begin
|
||||
if not BeginCodeTool(ActiveSrcEdit,ActiveUnitInfo,[]) then exit;
|
||||
{$IFDEF IDE_DEBUG}
|
||||
@ -15696,8 +15697,13 @@ begin
|
||||
ActiveSrcEdit.EditorComponent.CaretY,
|
||||
NewSource,NewX,NewY,NewTopLine) then
|
||||
begin
|
||||
Flags:=[jfFocusEditor];
|
||||
if (ActiveSrcEdit.EditorComponent.CaretY<>NewY)
|
||||
or (Abs(ActiveSrcEdit.EditorComponent.CaretX-NewX)>10)
|
||||
then
|
||||
Include(Flags,jfAddJumpPoint);
|
||||
DoJumpToCodePosition(ActiveSrcEdit, ActiveUnitInfo,
|
||||
NewSource, NewX, NewY, NewTopLine, [jfFocusEditor]);
|
||||
NewSource, NewX, NewY, NewTopLine, Flags);
|
||||
end else
|
||||
DoJumpToCodeToolBossError;
|
||||
end;
|
||||
|
Loading…
Reference in New Issue
Block a user