Diffstat (limited to 'noncore/net/opietooth/manager/popuphelper.h') (more/less context) (show whitespace changes)
-rw-r--r-- | noncore/net/opietooth/manager/popuphelper.h | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/noncore/net/opietooth/manager/popuphelper.h b/noncore/net/opietooth/manager/popuphelper.h new file mode 100644 index 0000000..7485f71 --- a/dev/null +++ b/noncore/net/opietooth/manager/popuphelper.h @@ -0,0 +1,25 @@ + +#ifndef OPIE_TOOTH_POPUP_HELPER +#define OPIE_TOOTH_POPUP_HELPER + +#include <qpopupmenu.h> +#include <qmap.h> + + +namespace OpieTooth { + typedef QPopupMenu* (*popupFactory)(void); + typedef QMap<int, popupFactory> FactoryMap; + class PopupHelper { + public: + PopupHelper(); + ~PopupHelper(); + void insert( int id, popupFactory fact ); + QPopupMenu* find( int id ); + private: + void init(); + FactoryMap m_map; + + }; +}; + +#endif |