aboutsummaryrefslogtreecommitdiff
path: root/src/plugger.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugger.h')
-rw-r--r--src/plugger.h16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/plugger.h b/src/plugger.h
index 57c2c0b..4faca92 100644
--- a/src/plugger.h
+++ b/src/plugger.h
@@ -55,6 +55,22 @@ extern "C" { \
55 (void (*)( void * ))(destroy ##classname) }; \ 55 (void (*)( void * ))(destroy ##classname) }; \
56} 56}
57 57
58#define PluginInterface3( structname, pluginname, classname, baseclass, name, ver, rev ) \
59extern "C" { \
60 baseclass *create ##classname() \
61 { \
62 return new classname(); \
63 } \
64 void destroy ##classname( baseclass *pCls ) \
65 { \
66 delete pCls; \
67 } \
68 PluginInfo structname = { \
69 #pluginname, name, ver, rev, \
70 (void *(*)())(create ##classname), \
71 (void (*)( void * ))(destroy ##classname) }; \
72}
73
58template<class T> 74template<class T>
59class Plugger 75class Plugger
60{ 76{