summaryrefslogtreecommitdiff
path: root/noncore/net/opietooth/manager/popuphelper.h
authorzecke <zecke>2002-07-09 18:28:19 (UTC)
committer zecke <zecke>2002-07-09 18:28:19 (UTC)
commit411ac6f9199b1aae2b6a40e7a8cf6bfea260acba (patch) (side-by-side diff)
tree218836d6509d2dcaba3c6306f9f488b759169b1a /noncore/net/opietooth/manager/popuphelper.h
parent5f549398401acc5591ffcb67459dbf55ea323b91 (diff)
downloadopie-411ac6f9199b1aae2b6a40e7a8cf6bfea260acba.zip
opie-411ac6f9199b1aae2b6a40e7a8cf6bfea260acba.tar.gz
opie-411ac6f9199b1aae2b6a40e7a8cf6bfea260acba.tar.bz2
Add a generic class for the sensitive QPopupMenu
Diffstat (limited to 'noncore/net/opietooth/manager/popuphelper.h') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/net/opietooth/manager/popuphelper.h25
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