diff -r 7197e789b953 -r ffa62e555b02 imagehandlingutilities/thumbnailmanager/tmcommon/src/tmactivitymanager.cpp --- a/imagehandlingutilities/thumbnailmanager/tmcommon/src/tmactivitymanager.cpp Fri Apr 16 15:16:16 2010 +0300 +++ b/imagehandlingutilities/thumbnailmanager/tmcommon/src/tmactivitymanager.cpp Mon May 03 12:48:51 2010 +0300 @@ -66,6 +66,7 @@ { TN_DEBUG1( "CTMActivityManager::ConstructL()"); iTimer.CreateLocal(); + iWatch = ENone; } // --------------------------------------------------------------------------- @@ -112,8 +113,6 @@ { TN_DEBUG1( "CTMActivityManager::Start()"); - iFirstRound = ETrue; - #ifdef MONITOR_LIGHTS if(!iLight) { @@ -121,11 +120,16 @@ } #endif - if( !IsActive() ) + if ( iWatch == ENone ) { - SetActive(); - TRequestStatus* statusPtr = &iStatus; - User::RequestComplete( statusPtr, KErrNone ); + iFirstRound = ETrue; + + if( !IsActive() ) + { + SetActive(); + TRequestStatus* statusPtr = &iStatus; + User::RequestComplete( statusPtr, KErrNone ); + } } } @@ -161,12 +165,12 @@ TN_DEBUG1( "CTMActivityManager::RunL() inactive"); NotifyObserver(); - if (!IsActive()) //observer might have called a Reset() - { - iTimer.Inactivity(iStatus,0); - iWatch = EWaitingForActivity; + if (!IsActive()) //observer might have called a Reset() + { + iTimer.Inactivity(iStatus,0); + iWatch = EWaitingForActivity; + } } - } else { iTimer.Inactivity(iStatus,iTimeout); @@ -174,8 +178,8 @@ } else if (iWatch == EWaitingForActivity) { - TN_DEBUG1( "CTMActivityManager::RunL() active"); - NotifyObserver(); + TN_DEBUG1( "CTMActivityManager::RunL() active"); + NotifyObserver(); if (!IsActive()) //observer might have called a Reset() {