]> git.lyx.org Git - lyx.git/blobdiff - src/frontends/xforms/Menubar_pimpl.h
Swap two printer related help messages.
[lyx.git] / src / frontends / xforms / Menubar_pimpl.h
index fadad7395530aa1ad73c262459219eb938c98407..9ffce98ca3516e479529cdf4915a24c21d8413ba 100644 (file)
 #endif
 
 #include <vector>
+#include <map>
 #include "LString.h"
 #include "frontends/Menubar.h"
+#include "commandtags.h"
 #include FORMS_H_LOCATION
 class LyXView;
 class MenuBackend;
 class MenuItem;
-class StrPool;
-
-#include "debug.h"
+class Menu;
 
 /** The LyX GUI independent menubar class
   The GUI interface is implemented in the corresponding Menubar_pimpl class. 
@@ -46,29 +46,28 @@ public:
        ///
        static void MenuCallback(FL_OBJECT *, long);
 
-       /// Add to "menu" the list of last opened files
-       /// (add "extra_label" to the last entry)
-       void add_lastfiles(int menu, string const & extra_label,
-                          std::vector<int> & smn, StrPool & strpool);
-       /// Add to "menu" the list of opened documents
-       /// (add "extra_label" to the last entry)
-       void add_documents(int menu, string const & extra_label,
-                          std::vector<int> & smn, StrPool & strpool);
        ///
-       int create_submenu(Window win, LyXView * view, 
-                          string const & menuname, 
-                          std::vector<int> & smn, StrPool & strpool);
+       void add_toc(int menu, string const & extra_label,
+                    std::vector<int> & smn, Window win);
+       ///
+       void add_references(int menu, string const & extra_label,
+                           std::vector<int> & smn, Window win);
+       ///
+       int create_submenu(Window win, LyXView * view,
+                           string const & menuname,
+                           std::vector<int> & smn);
 
+        /// update the state of the menuitems
+        void update() {}
 private:
-       ///
-       FL_OBJECT * frame_;
+       //
+       void makeMenubar(Menu const &menu);
+
        /// 
        LyXView * owner_;
        ///
        MenuBackend const * menubackend_;
        ///
-       string current_menu;
-       ///
        struct ItemInfo {
                ///
                ItemInfo(Menubar::Pimpl * p, MenuItem const * i, 
@@ -86,5 +85,14 @@ private:
        typedef std::vector<ItemInfo *> ButtonList;
        ///
        ButtonList buttonlist_;
+
+       ///
+       typedef std::map<string, FL_OBJECT *> MenubarMap;
+       ///
+       MenubarMap menubarmap_;
+       ///
+       string current_menu_name_;
+       ///
+       FL_OBJECT * current_group_;
 };
 #endif