From 67495a71d14b66c62f2927ad0da4070d17eeef19 Mon Sep 17 00:00:00 2001 From: Juergen Spitzmueller Date: Mon, 15 Oct 2018 08:04:31 +0200 Subject: [PATCH] Missing backports in the context of #9158 This fixes the remaining regressions in stable with citation --- src/Buffer.cpp | 5 +++++ src/insets/InsetBibtex.cpp | 7 +++++++ src/insets/InsetBibtex.h | 2 ++ 3 files changed, 14 insertions(+) diff --git a/src/Buffer.cpp b/src/Buffer.cpp index fce5b4ce97..1196874357 100644 --- a/src/Buffer.cpp +++ b/src/Buffer.cpp @@ -4808,6 +4808,11 @@ void Buffer::updateBuffer(UpdateScope scope, UpdateType utype) const if (master == this && !d->ignore_parent) { textclass.counters().reset(from_ascii("bibitem")); reloadBibInfoCache(); + // we will re-read this cache as we go through, but we need + // to know whether it's changed to know whether we need to + // update the bibinfo cache. + old_bibfiles = d->bibfiles_cache_; + d->bibfiles_cache_.clear(); } // keep the buffers to be children in this set. If the call from the diff --git a/src/insets/InsetBibtex.cpp b/src/insets/InsetBibtex.cpp index 9724e953ef..e4c7f302c4 100644 --- a/src/insets/InsetBibtex.cpp +++ b/src/insets/InsetBibtex.cpp @@ -879,6 +879,13 @@ void InsetBibtex::validate(LaTeXFeatures & features) const } +void InsetBibtex::updateBuffer(ParIterator const &, UpdateType) +{ + buffer().registerBibfiles(getBibFiles()); +} + + + docstring InsetBibtex::getRefLabel() const { if (buffer().masterParams().documentClass().hasLaTeXLayout("chapter")) diff --git a/src/insets/InsetBibtex.h b/src/insets/InsetBibtex.h index bcad1a6b95..c8a6592220 100644 --- a/src/insets/InsetBibtex.h +++ b/src/insets/InsetBibtex.h @@ -57,6 +57,8 @@ public: int plaintext(odocstringstream & ods, OutputParams const & op, size_t max_length = INT_MAX) const; /// + void updateBuffer(ParIterator const &, UpdateType); + /// void addToToc(DocIterator const & di, bool output_active, UpdateType utype, TocBackend & backend) const; /// -- 2.39.5