--- a/phonebookengines/VirtualPhonebook/inc/CVPbkETelCntConverter.h Tue Apr 27 16:23:35 2010 +0300
+++ b/phonebookengines/VirtualPhonebook/inc/CVPbkETelCntConverter.h Tue May 11 16:00:21 2010 +0300
@@ -147,6 +147,22 @@
TInt iMinContactLength;
};
+// CleanupStack helpers for item owning RPointerArrays
+template <class T>
+class CleanupResetAndDestroy
+ {
+public:
+ inline static void PushL(T& aRef)
+ { CleanupStack::PushL(TCleanupItem(&ResetAndDestroy,&aRef)); }
+private:
+ inline static void ResetAndDestroy(TAny *aPtr)
+ { static_cast<T*>(aPtr)->ResetAndDestroy(); }
+ };
+
+template <class T>
+inline void CleanupResetAndDestroyPushL(T& aRef)
+ { CleanupResetAndDestroy<T>::PushL(aRef); }
+
#endif // CVPBKETELCNTCONVERTER_H
// End of File