]> git.lyx.org Git - lyx.git/blobdiff - src/TextClass.cpp
This comment is wrong and causes bug in revision control.
[lyx.git] / src / TextClass.cpp
index ae37ebef15c1c73e1effa1b44d5bfe4e923888eb..2e5087f31389aefaa168b586115868d09589c3ff 100644 (file)
@@ -903,13 +903,6 @@ bool TextClass::hasLayout(docstring const & n) const
 }
 
 
-void TextClass::addLayoutIfNeeded(docstring const & n) const
-{
-       if (!hasLayout(n))
-               layoutlist_.push_back(createEmptyLayout(n, true));
-}
-
-
 Layout const & TextClass::operator[](docstring const & name) const
 {
        LASSERT(!name.empty(), /**/);
@@ -995,8 +988,17 @@ bool TextClass::load(string const & path) const
 }
 
 
+void DocumentClass::addLayoutIfNeeded(docstring const & n) const
+{
+       if (!hasLayout(n))
+               layoutlist_.push_back(createEmptyLayout(n, true));
+}
+
+
 InsetLayout const & DocumentClass::insetLayout(docstring const & name) const 
 {
+       // FIXME The fix for the InsetLayout part of 4812 would be here:
+       // Add the InsetLayout to the document class if it is not found.
        docstring n = name;
        InsetLayouts::const_iterator cen = insetlayoutlist_.end();
        while (!n.empty()) {