# HG changeset patch # User Dremov Kirill (Nokia-D-MSW/Tampere) # Date 1284494558 -10800 # Node ID 78e19bc09b730e996ab5b648391a18510e684e82 # Parent 31fccae4f8a7ef7044219a820e95a0169f0a2d4e Revision: 201033 Kit: 201035 diff -r 31fccae4f8a7 -r 78e19bc09b73 uiacceltk/hitchcock/goommonitor/src/goommemorymonitor.cpp --- a/uiacceltk/hitchcock/goommonitor/src/goommemorymonitor.cpp Wed Sep 01 12:16:53 2010 +0100 +++ b/uiacceltk/hitchcock/goommonitor/src/goommemorymonitor.cpp Tue Sep 14 23:02:38 2010 +0300 @@ -205,9 +205,10 @@ FUNC_LOG; // keep only one notification active at a moment #ifdef USE_ASYNCYH_NOTIFICATIONS - TInt current = GetFreeMemory(); + if (aThreshold == EGL_PROF_TOTAL_MEMORY_USAGE_LT_NOK) { + TInt current = GetFreeMemory(); if(current >= iGoodThreshold && (!NeedToPostponeMemGood())) { TRACES2("FreeMemThresholdCrossedL : crossed good threshold Free %d, GThresh %d, Calling MemoryGood",current, iGoodThreshold); @@ -229,20 +230,15 @@ } else//if aThreshold == EGL_PROF_TOTAL_MEMORY_USAGE_GT_NOK { - if(current < iLowThreshold) + TRACES1("FreeMemThresholdCrossedL : crossed low threshold %d", iLowThreshold); + iMemAllocationsGrowing->Stop(); + iMemAllocationsGoingDown->Continue(); + if((iTrigger == EGOomTriggerNone) && !NeedToPostponeMemGood()) { - TRACES1("FreeMemThresholdCrossedL : crossed low threshold %d", iLowThreshold); - iMemAllocationsGrowing->Stop(); - iMemAllocationsGoingDown->Continue(); - if((iTrigger == EGOomTriggerNone) && !NeedToPostponeMemGood()) - { - if(iSynchTimer->IsActive()) - iSynchTimer->Cancel(); - StartFreeSomeRamL(iGoodThreshold, EGOomTriggerThresholdCrossed); - } + if(iSynchTimer->IsActive()) + iSynchTimer->Cancel(); + StartFreeSomeRamL(iGoodThreshold, EGOomTriggerThresholdCrossed); } - else - TRACES2("FreeMemThresholdCrossedL : crossed low threshold %d, FALSE ALARM, FreeMem = %d", iLowThreshold, current); } #endif }