diff -r 0ed94ceaa377 -r cb62a4f66ebe webengine/osswebengine/MemoryManager/Src/MemoryManager.cpp --- a/webengine/osswebengine/MemoryManager/Src/MemoryManager.cpp Thu Dec 17 09:20:16 2009 +0200 +++ b/webengine/osswebengine/MemoryManager/Src/MemoryManager.cpp Thu Jan 07 13:31:38 2010 +0200 @@ -18,7 +18,7 @@ // INCLUDE FILES -#include "MemoryManager.h" +#include #include "MemoryPool.h" #include "FastAllocator.h" #include "MemoryLogger.h" @@ -32,16 +32,6 @@ // initializing a global memory pool. static CMemoryPool *s_pool = 0; -struct cleanupMemoryPool { - ~cleanupMemoryPool() { - if(s_pool) - { - delete s_pool; - s_pool = NULL; - } - } -}; -static cleanupMemoryPool deleteMemoryPool; //----------------------------------------------------------------------------- // Pool() - a utility function for accessing the right memory pool @@ -113,6 +103,32 @@ } //----------------------------------------------------------------------------- +// MemoryManager::InitOOMHandler +//----------------------------------------------------------------------------- +EXPORT_C void MemoryManager::InitOOMDialog() + { +#ifdef __NEW_ALLOCATOR__ + if (s_pool) + { + ((CNewSymbianHeapPool *)s_pool)->InitOOMDialog(); + } +#endif + } + +//----------------------------------------------------------------------------- +// MemoryManager::ResetOOMDialogDisplayed +//----------------------------------------------------------------------------- +EXPORT_C void MemoryManager::ResetOOMDialogDisplayed() + { +#ifdef __NEW_ALLOCATOR__ + if (s_pool) + { + ((CNewSymbianHeapPool *)s_pool)->ResetOOMDialogDisplayed(); + } +#endif + } + +//----------------------------------------------------------------------------- // MemoryManager::CloseFastAllocator //----------------------------------------------------------------------------- EXPORT_C void MemoryManager::CloseFastAllocator(RAllocator* aDefaultAllocator)