mirror of https://gitlab.com/basile.b/dexed.git
fix #194 - search, problem with consecutive matches
This commit is contained in:
parent
6c27ffbc95
commit
23652be83b
|
@ -376,7 +376,7 @@ procedure TCESearchWidget.actFindNextExecute(sender: TObject);
|
||||||
begin
|
begin
|
||||||
if fDoc.isNil then exit;
|
if fDoc.isNil then exit;
|
||||||
//
|
//
|
||||||
fSearchMru.Insert(0,fToFind);
|
fSearchMru.Insert(0, fToFind);
|
||||||
cbToFind.Items.Assign(fSearchMru);
|
cbToFind.Items.Assign(fSearchMru);
|
||||||
//
|
//
|
||||||
if not chkFromCur.Checked then
|
if not chkFromCur.Checked then
|
||||||
|
@ -386,7 +386,7 @@ begin
|
||||||
else
|
else
|
||||||
begin
|
begin
|
||||||
if not fHasRestarted then
|
if not fHasRestarted then
|
||||||
fDoc.CaretXY := Point(0,0);
|
fDoc.CaretXY := Point(1,1);
|
||||||
fHasRestarted := true;
|
fHasRestarted := true;
|
||||||
end;
|
end;
|
||||||
end
|
end
|
||||||
|
@ -395,7 +395,7 @@ begin
|
||||||
if chkBack.Checked then
|
if chkBack.Checked then
|
||||||
fDoc.CaretX := fDoc.CaretX - 1
|
fDoc.CaretX := fDoc.CaretX - 1
|
||||||
else
|
else
|
||||||
fDoc.CaretX := fDoc.CaretX + fToFind.length;
|
fDoc.CaretX := fDoc.CaretX + 1;
|
||||||
end;
|
end;
|
||||||
if fDoc.SearchReplace(fToFind, '', getOptions) = 0 then
|
if fDoc.SearchReplace(fToFind, '', getOptions) = 0 then
|
||||||
dlgOkInfo('the expression cannot be found')
|
dlgOkInfo('the expression cannot be found')
|
||||||
|
|
Loading…
Reference in New Issue