From 35fa80283050b2541eef708672bf412efbc04bf2 Mon Sep 17 00:00:00 2001 From: Julien Rioux Date: Mon, 12 Dec 2011 16:38:04 +0000 Subject: [PATCH] Move some code to applyView(). Previous commit did not distinguish whether the changes were applied or cancelled. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@40487 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/frontends/qt4/GuiDocument.cpp | 8 ++++++-- src/frontends/qt4/GuiDocument.h | 2 ++ 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/src/frontends/qt4/GuiDocument.cpp b/src/frontends/qt4/GuiDocument.cpp index 2f8eb7d794..f7cffd1a78 100644 --- a/src/frontends/qt4/GuiDocument.cpp +++ b/src/frontends/qt4/GuiDocument.cpp @@ -1990,8 +1990,7 @@ void GuiDocument::languagePackageChanged(int i) void GuiDocument::biblioChanged() { - buffer().invalidateBibinfoCache(); - buffer().removeBiblioTempFiles(); + biblioChanged_ = true; changed(); } @@ -2264,6 +2263,11 @@ void GuiDocument::applyView() else bp_.bibtex_command = bibtex_command + " " + bibtex_options; + if (biblioChanged_) { + buffer().invalidateBibinfoCache(); + buffer().removeBiblioTempFiles(); + } + // Indices indicesModule->apply(bp_); diff --git a/src/frontends/qt4/GuiDocument.h b/src/frontends/qt4/GuiDocument.h index bb71c9455c..fa0e504d29 100644 --- a/src/frontends/qt4/GuiDocument.h +++ b/src/frontends/qt4/GuiDocument.h @@ -249,6 +249,8 @@ private: std::map changedBranches_; /// std::list includeonlys_; + /// + bool biblioChanged_; }; -- 2.39.2