#include "LyX.h"
#include "LyXAction.h"
#include "lyxfind.h"
-#include "LyXFunc.h"
#include "Layout.h"
#include "LyXRC.h"
#include "MetricsInfo.h"
#include "insets/InsetRef.h"
#include "insets/InsetText.h"
#include "insets/InsetNote.h"
-#include "insets/InsetERT.h"
#include "frontends/alert.h"
#include "frontends/Application.h"
setCursor(backcur.asDocIterator(&buffer_));
buffer_.errors("Class Switch");
- buffer_.updateLabels();
+ buffer_.updateBuffer();
}
/** Return the change status at cursor position, taking in account the
flag.setEnabled(true);
break;
- case LFUN_REGEXP_MODE:
- // FIXME: Test if current WorkArea is the search WorkArea
- flag.setEnabled(buffer().isInternal() && !cur.inRegexped() && !dynamic_cast<InsetERT*>(&cur.inset()));
- break;
-
case LFUN_LABEL_COPY_AS_REF: {
// if there is an inset at cursor, see whether it
// handles the lfun
dr.update(Update::Force | Update::FitCursor);
} else {
// Switch to other buffer view and resend cmd
- theLyXFunc().dispatch(FuncRequest(
+ lyx::dispatch(FuncRequest(
LFUN_BUFFER_SWITCH, b->absFileName()));
- theLyXFunc().dispatch(cmd);
+ lyx::dispatch(cmd);
}
break;
}
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"));
+ lyx::dispatch(FuncRequest(LFUN_DIALOG_SHOW, "findreplace"));
break;
}
if (find(this, req))
d->cursor_ = cur;
- buffer_.updateLabels();
+ buffer_.updateBuffer();
buffer_.changed(true);
return true;
}