it->fillWithBibKeys(d->bibinfo_, it);
This could be useful later, if we decide to try to do the work that
fillWithBibKeys did from updateLabels().
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@35106
a592a061-630c-0410-9148-
cb99ea01b6c8
if (!d->bibinfo_cache_valid_) {
d->bibinfo_.clear();
for (InsetIterator it = inset_iterator_begin(inset()); it; ++it)
if (!d->bibinfo_cache_valid_) {
d->bibinfo_.clear();
for (InsetIterator it = inset_iterator_begin(inset()); it; ++it)
- it->fillWithBibKeys(d->bibinfo_, it);
+ it->fillWithBibKeys(d->bibinfo_);
d->bibinfo_cache_valid_ = true;
}
}
d->bibinfo_cache_valid_ = true;
}
}
/// pit is the ParConstIterator of the paragraph containing the inset
virtual void addToToc(DocIterator const &) {}
/// Fill keys with BibTeX information
/// pit is the ParConstIterator of the paragraph containing the inset
virtual void addToToc(DocIterator const &) {}
/// Fill keys with BibTeX information
- virtual void fillWithBibKeys(BiblioInfo &, InsetIterator const &) const {}
+ virtual void fillWithBibKeys(BiblioInfo &) const {}
/// Update the counters of this inset and of its contents.
/// The boolean indicates whether we are preparing for output, e.g.,
/// of XHTML.
/// Update the counters of this inset and of its contents.
/// The boolean indicates whether we are preparing for output, e.g.,
/// of XHTML.
-void InsetBibitem::fillWithBibKeys(BiblioInfo & keys, InsetIterator const & it) const
+void InsetBibitem::fillWithBibKeys(BiblioInfo & keys) const
{
docstring const key = getParam("key");
{
docstring const key = getParam("key");
+ // false means it's not BibTeX
BibTeXInfo keyvalmap(false);
keyvalmap.label(bibLabel());
BibTeXInfo keyvalmap(false);
keyvalmap.label(bibLabel());
+ // The indirection here is a little annoying, but
+ // DocIterator(Buffer *, Inset *)
+ // is private.
+ InsetBibitem & me = const_cast<InsetBibitem &>(*this);
+ InsetIterator it(me);
DocIterator doc_it(it);
doc_it.forwardPos();
keyvalmap[from_ascii("ref")] = doc_it.paragraph().asString();
DocIterator doc_it(it);
doc_it.forwardPos();
keyvalmap[from_ascii("ref")] = doc_it.paragraph().asString();
///
docstring xhtml(XHTMLStream &, OutputParams const &) const;
///
///
docstring xhtml(XHTMLStream &, OutputParams const &) const;
///
- virtual void fillWithBibKeys(BiblioInfo &, InsetIterator const &) const;
+ virtual void fillWithBibKeys(BiblioInfo &) const;
/// Update the counter of this inset
void updateBuffer(ParIterator const &, UpdateType);
///
/// Update the counter of this inset
void updateBuffer(ParIterator const &, UpdateType);
///
// This method returns a comma separated list of Bibtex entries
// This method returns a comma separated list of Bibtex entries
-void InsetBibtex::fillWithBibKeys(BiblioInfo & keylist,
- InsetIterator const & /*di*/) const
+void InsetBibtex::fillWithBibKeys(BiblioInfo & keylist) const
{
// This bibtex parser is a first step to parse bibtex files
// more precisely.
{
// This bibtex parser is a first step to parse bibtex files
// more precisely.
///
int latex(odocstream &, OutputParams const &) const;
///
///
int latex(odocstream &, OutputParams const &) const;
///
- void fillWithBibKeys(BiblioInfo &, InsetIterator const &) const;
+ void fillWithBibKeys(BiblioInfo &) const;
///
support::FileNameList getBibFiles() const;
///
///
support::FileNameList getBibFiles() const;
///
-void InsetInclude::fillWithBibKeys(BiblioInfo & keys,
- InsetIterator const & /*di*/) const
+void InsetInclude::fillWithBibKeys(BiblioInfo & keys) const
- string const included_file = includedFileName(buffer(), params()).absFileName();
- Buffer * tmp = theBufferList().getBuffer(FileName(included_file));
+ string const included_file =
+ includedFileName(buffer(), params()).absFileName();
+ Buffer * tmp =
+ theBufferList().getBuffer(FileName(included_file));
BiblioInfo const & newkeys = tmp->localBibInfo();
keys.mergeBiblioInfo(newkeys);
}
BiblioInfo const & newkeys = tmp->localBibInfo();
keys.mergeBiblioInfo(newkeys);
}
* \param keys the list of bibkeys in the child buffer.
* \param it not used here
*/
* \param keys the list of bibkeys in the child buffer.
* \param it not used here
*/
- void fillWithBibKeys(BiblioInfo & keys, InsetIterator const & it) const;
+ void fillWithBibKeys(BiblioInfo & keys) const;
///
bool hasSettings() const { return true; }
///
bool hasSettings() const { return true; }