switch (cmd.action) {
case LFUN_UNKNOWN_ACTION:
-#ifndef HAVE_LIBAIKSAURUS
+#if !defined(HAVE_LIBMYTHES) && !defined(HAVE_LIBAIKSAURUS)
case LFUN_THESAURUS_ENTRY:
#endif
flag.unknown(true);
theApp()->dispatch(FuncRequest(LFUN_WINDOW_NEW));
string const arg = argument;
if (arg.empty()) {
- setErrorMessage(from_ascii(N_("Missing argument")));
+ setErrorMessage(from_utf8(N_("Missing argument")));
break;
}
FileName const fname = i18nLibFileSearch("doc", arg, "lyx");
case LFUN_COMMAND_SEQUENCE: {
// argument contains ';'-terminated commands
string arg = argument;
+ if (theBufferList().isLoaded(buffer))
+ buffer->undo().beginUndoGroup();
while (!arg.empty()) {
string first;
arg = split(arg, first, ';');
func.origin = cmd.origin;
dispatch(func);
}
+ if (theBufferList().isLoaded(buffer))
+ buffer->undo().endUndoGroup();
break;
}
// The user has already confirmed that the changes, if any, should
// be discarded. So we just release the Buffer and don't call closeBuffer();
theBufferList().release(lyx_view_->buffer());
+ // if the lyx_view_ has been destroyed, create a new one
+ if (!lyx_view_)
+ theApp()->dispatch(FuncRequest(LFUN_WINDOW_NEW));
Buffer * buf = lyx_view_->loadDocument(filename);
docstring const disp_fn = makeDisplayPath(filename.absFilename());
docstring str;
oldlayout, buf->params().documentClassPtr(),
static_cast<InsetText &>(buf->inset()), el);
- view()->setCursor(backcur.asDocIterator(&(buf->inset())));
+ view()->setCursor(backcur.asDocIterator(buf));
buf->errors("Class Switch");
buf->updateLabels();
if (lyxrc_orig.windows_style_tex_paths != lyxrc_new.windows_style_tex_paths) {
os::windows_style_tex_paths(lyxrc_new.windows_style_tex_paths);
}
+ case LyXRC::RC_THESAURUSDIRPATH:
case LyXRC::RC_UIFILE:
case LyXRC::RC_USER_EMAIL:
case LyXRC::RC_USER_NAME: