From 14d7b574870c324508a2eaae5019fece2e5f7cee Mon Sep 17 00:00:00 2001 From: Richard Heck Date: Thu, 14 Feb 2008 07:10:12 +0000 Subject: [PATCH] Cleanup. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@22996 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/BiblioInfo.h | 4 ++-- src/frontends/qt4/GuiCitation.cpp | 20 ++++++++++---------- src/insets/InsetBibtex.cpp | 2 +- 3 files changed, 13 insertions(+), 13 deletions(-) diff --git a/src/BiblioInfo.h b/src/BiblioInfo.h index 25d86616fc..20c0dff158 100644 --- a/src/BiblioInfo.h +++ b/src/BiblioInfo.h @@ -106,9 +106,9 @@ public: docstring & operator[](docstring const & f) { return bimap_[f]; } /// - docstring allData() const { return allData_; } + docstring const & allData() const { return allData_; } /// - void allData(docstring const & d) { allData_ = d; } + void setAllData(docstring const & d) { allData_ = d; } /// docstring entryType() const { return entryType_; } private: diff --git a/src/frontends/qt4/GuiCitation.cpp b/src/frontends/qt4/GuiCitation.cpp index 1c6499586f..5b668f0b34 100644 --- a/src/frontends/qt4/GuiCitation.cpp +++ b/src/frontends/qt4/GuiCitation.cpp @@ -376,15 +376,15 @@ void GuiCitation::findText(QString const & text, bool reset) //"All Entry Types" is first. index = entriesCO->currentIndex() - 1; vector const & entries = availableEntries(); - docstring entryType; + docstring entry_type; if (index < 0 || index >= int(entries.size())) - entryType = from_ascii(""); + entry_type = from_ascii(""); else - entryType = entries[index]; + entry_type = entries[index]; bool const case_sentitive = caseCB->checkState(); bool const reg_exp = regexCB->checkState(); - findKey(text, onlyKeys, field, entryType, + findKey(text, onlyKeys, field, entry_type, case_sentitive, reg_exp, reset); //FIXME //It'd be nice to save and restore the current selection in @@ -505,7 +505,7 @@ void GuiCitation::init() void GuiCitation::findKey(QString const & str, bool only_keys, - docstring field, docstring entryType, + docstring field, docstring entry_type, bool case_sensitive, bool reg_exp, bool reset) { // Used for optimisation: store last searched string. @@ -541,10 +541,10 @@ void GuiCitation::findKey(QString const & str, bool only_keys, QStringList result; - // First, filter by entryType, which will be faster than + // First, filter by entry_type, which will be faster than // what follows, so we may get to do that on less. vector keyVector = to_docstring_vector(keys); - filterByEntryType(keyVector, entryType); + filterByEntryType(keyVector, entry_type); if (str.isEmpty()) result = to_qstring_list(keyVector); @@ -627,9 +627,9 @@ vector const GuiCitation::availableEntries() const void GuiCitation::filterByEntryType( - vector & keyVector, docstring entryType) + vector & keyVector, docstring entry_type) { - if (entryType.empty()) + if (entry_type.empty()) return; vector::iterator it = keyVector.begin(); @@ -641,7 +641,7 @@ void GuiCitation::filterByEntryType( BiblioInfo::const_iterator cit = bibkeysInfo_.find(key); if (cit == bibkeysInfo_.end()) continue; - if (cit->second.entryType() == entryType) + if (cit->second.entryType() == entry_type) result.push_back(key); } keyVector = result; diff --git a/src/insets/InsetBibtex.cpp b/src/insets/InsetBibtex.cpp index 999781b26b..704cedeb0c 100644 --- a/src/insets/InsetBibtex.cpp +++ b/src/insets/InsetBibtex.cpp @@ -772,7 +772,7 @@ void InsetBibtex::fillWithBibKeys(Buffer const & buffer, // add the new entry keylist.addEntryType(entryType); - keyvalmap.allData(data); + keyvalmap.setAllData(data); keylist[key] = keyvalmap; } } //< searching '@'