FuncRequest req = cmd;
if (cmd.argument().empty() && !d->search_request_cache_.argument().empty())
req = d->search_request_cache_;
+ if (req.argument().empty()) {
+ theLyXFunc().dispatch(FuncRequest(LFUN_DIALOG_SHOW, "findreplace"));
+ break;
+ }
if (find(this, req))
showCursor();
else
// Inset is not at cursor position. Find it in the document.
Cursor cur(*this);
cur.reset(buffer().inset());
- do
+ while (cur && cur.nextInset() != inset)
cur.forwardInset();
- while (cur && cur.nextInset() != inset);
if (cur) {
setCursor(cur);