-rw-r--r-- | microkde/kstaticdeleter.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/microkde/kstaticdeleter.h b/microkde/kstaticdeleter.h index 190f3e4..dfd3929 100644 --- a/microkde/kstaticdeleter.h +++ b/microkde/kstaticdeleter.h | |||
@@ -23,13 +23,15 @@ | |||
23 | #ifndef _KSTATIC_DELETER_H_ | 23 | #ifndef _KSTATIC_DELETER_H_ |
24 | #define _KSTATIC_DELETER_H_ | 24 | #define _KSTATIC_DELETER_H_ |
25 | 25 | ||
26 | template<class type> | 26 | template<class type> |
27 | class KStaticDeleter | 27 | class KStaticDeleter |
28 | { | 28 | { |
29 | public: | 29 | public: |
30 | KStaticDeleter() {}; | 30 | KStaticDeleter() {}; |
31 | type *setObject( type *obj, bool isArray = false) { return obj; } | 31 | type *setObject( type *obj, bool isArray = false) { _mobj = obj;return obj; } |
32 | virtual ~KStaticDeleter() {}; | 32 | virtual ~KStaticDeleter() {delete _mobj;}; |
33 | private: | ||
34 | type* _mobj; | ||
33 | }; | 35 | }; |
34 | 36 | ||
35 | #endif | 37 | #endif |