]> git.lyx.org Git - lyx.git/blobdiff - src/Buffer.cpp
Provide proper fallback if a bibliography processor is not found
[lyx.git] / src / Buffer.cpp
index 3a8fae7a57ade0753671936d2a9bbb3a967a88c0..ec480f7584366bb26e987049a4d764a98387fa36 100644 (file)
@@ -2598,16 +2598,14 @@ void Buffer::collectBibKeys(FileNameList & checkedFiles) const
 
 void Buffer::addBiblioInfo(BiblioInfo const & bin) const
 {
-       // We add the biblio info to the master buffer,
-       // if there is one, but also to every single buffer,
-       // in case a child is compiled alone.
+       // We add the biblio info to the parent buffer,
+       // if there is one, but also to this buffer, in case
+       // it is compiled alone.
        BiblioInfo & bi = d->bibinfo_;
        bi.mergeBiblioInfo(bin);
 
-       if (parent() != 0) {
-               BiblioInfo & masterbi = parent()->d->bibinfo_;
-               masterbi.mergeBiblioInfo(bin);
-       }
+       if (parent())
+               parent()->addBiblioInfo(bin);
 }
 
 
@@ -4480,7 +4478,7 @@ Buffer::ExportStatus Buffer::doExport(string const & target, bool put_in_tempdir
                                // file (not for previewing).
                                Alert::error(_("Couldn't export file"), bformat(
                                        _("No information for exporting the format %1$s."),
-                                       theFormats().prettyName(format)));
+                                       translateIfPossible(theFormats().prettyName(format))));
                        }
                        return ExportNoPathToFormat;
                }
@@ -4664,13 +4662,13 @@ Buffer::ExportStatus Buffer::doExport(string const & target, bool put_in_tempdir
                } else {
                        message(bformat(_("Document exported as %1$s "
                                "to file `%2$s'"),
-                               theFormats().prettyName(format),
+                               translateIfPossible(theFormats().prettyName(format)),
                                makeDisplayPath(result_file)));
                }
        } else {
                // This must be a dummy converter like fax (bug 1888)
                message(bformat(_("Document exported as %1$s"),
-                       theFormats().prettyName(format)));
+                       translateIfPossible(theFormats().prettyName(format))));
        }
 
        return success ? ExportSuccess : ExportConverterError;
@@ -5267,11 +5265,6 @@ void Buffer::updateBuffer(ParIterator & parit, UpdateType utype) const
        // to resolve macros in it.
        parit.text()->setMacrocontextPosition(parit);
 
-       // Reset bibitem counter in master (#8499)
-       Buffer const * const master = masterBuffer();
-       if (master == this && !d->ignore_parent)
-               master->params().documentClass().counters().reset(from_ascii("bibitem"));
-
        depth_type maxdepth = 0;
        pit_type const lastpit = parit.lastpit();
        for ( ; parit.pit() <= lastpit ; ++parit.pit()) {