]> git.lyx.org Git - lyx.git/blobdiff - src/TocBackend.cpp
Fix bug #12772
[lyx.git] / src / TocBackend.cpp
index 90e7675a98b510e4ead7d1764ce372c502df2e9b..c0a4373923f631eb51a29688cd5051db2c927b19 100644 (file)
@@ -43,8 +43,8 @@ namespace lyx {
 ///////////////////////////////////////////////////////////////////////////
 
 TocItem::TocItem(DocIterator const & dit, int d, docstring const & s,
-                 bool output_active, FuncRequest const & action)
-       : dit_(dit), depth_(d), str_(s), output_(output_active),
+                 bool output_active, bool missing, FuncRequest const & action)
+       : dit_(dit), depth_(d), str_(s), output_(output_active), missing_(missing),
          action_(action)
 {
 }
@@ -65,6 +65,9 @@ docstring const TocItem::asString() const
                prefix += cross;
                prefix += thin;
        }
+       if (missing_) {
+               prefix += _("MISSING: ");
+       }
        return prefix + str_;
 }
 
@@ -143,8 +146,8 @@ shared_ptr<Toc> TocBackend::toc(string const & type)
 
 TocBuilder & TocBackend::builder(string const & type)
 {
-       auto p = make_unique<TocBuilder>(toc(type));
-       return * builders_.insert(make_pair(type, move(p))).first->second;
+       auto p = lyx::make_unique<TocBuilder>(toc(type));
+       return * builders_.insert(make_pair(type, std::move(p))).first->second;
 }