]> git.lyx.org Git - lyx.git/blobdiff - src/insets/InsetFoot.cpp
* src/insets/InsetTabular.h:
[lyx.git] / src / insets / InsetFoot.cpp
index 2785c51a68689ffb4e463a5acefe6d1ed5bdb124..bace67f593a15583867e321df81a94615bd35ab4 100644 (file)
@@ -16,7 +16,6 @@
 #include "Buffer.h"
 #include "BufferParams.h"
 #include "Counters.h"
-#include "support/gettext.h"
 #include "Layout.h"
 // FIXME: the following is needed just to get the layout of the enclosing
 // paragraph. This seems a bit too much to me (JMarc)
@@ -27,6 +26,7 @@
 
 #include "support/debug.h"
 #include "support/docstream.h"
+#include "support/gettext.h"
 #include "support/lstrings.h"
 
 using namespace std;
@@ -64,16 +64,17 @@ void InsetFoot::updateLabels(ParIterator const & it)
 }
 
 
-void InsetFoot::addToToc(ParConstIterator const & cpit) const
+void InsetFoot::addToToc(DocIterator const & cpit)
 {
-       ParConstIterator pit = cpit;
-       pit.push_back(*this);
+       DocIterator pit = cpit;
+       pit.push_back(CursorSlice(*this));
 
        Toc & toc = buffer().tocBackend().toc("footnote");
-       // FIXME: we probably want the footnote number too.
        docstring str;
        str = custom_label_ + ": " + getNewLabel(str);
        toc.push_back(TocItem(pit, 0, str));
+       // Proceed with the rest of the inset.
+       InsetFootlike::addToToc(cpit);
 }