1 #ifndef VVTOOLMANAGER_H
2 #define VVTOOLMANAGER_H
3 #include "clitkCommon.h"
5 class vvToolCreatorBase;
6 class vvMainWindowBase;
8 //------------------------------------------------------------------------------
9 // Manage a list of ToolCreator. Each tool will be automagically
10 // inserted into a list at construction time, before main. Then the
11 // MainWindow will call the 'Initialize' to insert the tool in the
17 /// Get or build unique instance with this method
18 static vvToolManager * GetInstance();
20 /// Add a tool creator in the list (called before main, via static member initialization)
21 static void AddTool(vvToolCreatorBase * v);
23 /// Called in MainWindow, insert all tools into the menu
24 static void InsertToolsInMenu(vvMainWindowBase * m);
28 /// Singleton object pointer
29 static vvToolManager * mSingleton;
31 /// list of all tool creators
32 std::vector<vvToolCreatorBase *> mListOfTools;
34 //------------------------------------------------------------------------------