Fixed issue #8543 also for advanced search (cursor moved at proper end of selection before starting Find Advanced operation).

This commit is contained in:
Tommaso Cucinotta 2013-04-04 00:43:36 +01:00
parent be96eec1c8
commit 1129eb0342
2 changed files with 5 additions and 0 deletions

View File

@ -1422,6 +1422,9 @@ bool findAdv(BufferView * bv, FindAndReplaceOptions const & opt)
try {
MatchStringAdv matchAdv(bv->buffer(), opt);
int length = bv->cursor().selectionEnd().pos() - bv->cursor().selectionBegin().pos();
if (length > 0)
bv->putSelectionAt(bv->cursor().selectionBegin(), length, !opt.forward);
findAdvReplace(bv, opt, matchAdv);
cur = bv->cursor();
if (opt.forward)

View File

@ -214,6 +214,8 @@ What's new
- Fixed problem when searching with regular expressions and ignore
format off (bug 8382).
- Cursor moved at proper end of selection before starting Find Advanced operation (fixing issue #8543 for advanced search)
* BUILD/INSTALLATION