]> git.lyx.org Git - lyx.git/blobdiff - src/frontends/controllers/ControlToc.h
fix crash due to invalidated iterator
[lyx.git] / src / frontends / controllers / ControlToc.h
index 86d151f8cef760c9a0f4a4e094e1d820daab82c4..f71751c2fe4e12e41fa2c0cd37a68e1aa91d2589 100644 (file)
@@ -17,6 +17,9 @@
 #include "toc.h"
 #include <vector>
 
+namespace lyx {
+namespace frontend {
+
 /** A controller for TOC dialogs.
  */
 class ControlToc : public ControlCommand {
@@ -25,13 +28,19 @@ public:
        ControlToc(Dialog &);
 
        /// Goto this paragraph id
-       void goTo(lyx::toc::TocItem const &);
+       void goTo(toc::TocItem const &);
 
        /// Return the list of types available
-       std::vector<string> const getTypes() const;
+       std::vector<std::string> const getTypes() const;
+
+       /// Return the guiname from a given cmdName of the TOC param
+       std::string const getGuiName(std::string const & type) const;
 
        /// Given a type, returns the contents
-       lyx::toc::Toc const getContents(string const & type) const;
+       toc::Toc const getContents(std::string const & type) const;
 };
 
+} // namespace frontend
+} // namespace lyx
+
 #endif // CONTROLTOC_H