X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2Flyxfind.C;h=d8e08dd8036e174e418ff4ceb05871c29bb2ddcd;hb=3d2184730a436d56dd4e3ddad1f067d8bb14200e;hp=14d84cd857e277d8fb8517f880ea963755b9bf79;hpb=55f575c4dd64dfa0545d7ec044a3718e0e26d778;p=lyx.git diff --git a/src/lyxfind.C b/src/lyxfind.C index 14d84cd857..d8e08dd803 100644 --- a/src/lyxfind.C +++ b/src/lyxfind.C @@ -18,6 +18,7 @@ #include "buffer.h" #include "cursor.h" #include "CutAndPaste.h" +#include "buffer_funcs.h" #include "BufferView.h" #include "debug.h" #include "funcrequest.h" @@ -28,6 +29,7 @@ #include "undo.h" #include "frontends/Alert.h" +#include "frontends/Selection.h" #include "support/convert.h" #include "support/docstream.h" @@ -190,7 +192,7 @@ int replaceAll(BufferView * bv, ++num; } - bv->buffer()->text().init(bv); + updateLabels(buf); bv->putSelectionAt(doc_iterator_begin(buf.inset()), 0, false); if (num) buf.markDirty(); @@ -355,6 +357,7 @@ bool findNextChange(BufferView * bv) // Now put cursor to end of selection: bv->cursor().setCursor(cur); bv->cursor().setSelection(); + theSelection().haveSelection(bv->cursor().selection()); // if we used a lfun like in find/replace, dispatch would do // that for us bv->update();