Commit 9d7274a0 authored by Juha Manninen's avatar Juha Manninen
Browse files

IDE: Ask 'Continue search from the beginning?' only when not already in...

IDE: Ask 'Continue search from the beginning?' only when not already in beginning. Issue #28177, patch from Ondrej Pokorny.

git-svn-id: trunk@49171 -
parent 8077f553
......@@ -3061,7 +3061,11 @@ begin
Manager.AddJumpPointClicked(Self);
OldEntireScope := ssoEntireScope in anOptions;
Again:=False;
//do not show lisUESearchStringContinueBeg/lisUESearchStringContinueEnd if the caret is in the beginning/end
if ssoBackwards in anOptions then
Again := ((FEditor.CaretY >= FEditor.Lines.Count) and (FEditor.CaretX > Length(FEditor.LineText)))//caret in the last line and last character
else
Again := ((FEditor.CaretY = 1) and (FEditor.CaretX = 1));//caret at the top/left
repeat
try
Result:=EditorComponent.SearchReplace(aFindText, aReplaceText, anOptions);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment