]> git.lyx.org Git - features.git/commitdiff
Fix confusing behavior in search when changing directions (bug 8543)
authorJean-Marc Lasgouttes <lasgouttes@lyx.org>
Fri, 22 Feb 2013 10:06:25 +0000 (11:06 +0100)
committerJean-Marc Lasgouttes <lasgouttes@lyx.org>
Fri, 22 Feb 2013 17:16:04 +0000 (18:16 +0100)
src/lyxfind.cpp
status.20x

index 50a2a5776db4b55100636a35fed2ee00c0f73417..f74da52f0c4e0f04b73f9918aa0032c084c5f0aa 100644 (file)
@@ -154,7 +154,9 @@ bool findOne(BufferView * bv, docstring const & searchstr,
        if (!searchAllowed(searchstr))
                return false;
 
-       DocIterator cur = bv->cursor();
+       DocIterator cur = forward 
+               ? bv->cursor().selectionEnd() 
+               : bv->cursor().selectionBegin();
 
        MatchString const match(searchstr, case_sens, whole);
 
index b1f0ba3773390abb52c3f17186d535667cf60df3..d00dbe3aa0123e7e52ba38522ffc1d1ca4cbeed6 100644 (file)
@@ -130,6 +130,8 @@ What's new
 
 - Fix a few selection bugs in tabular (bugs 4981, 7988).
 
+- Fix confusing behavior in search when changing directions (bug 8543)
+
 - Fix several issues when using multicolumns/multirows and decimal alignment in
   table cells (bug 8285).