equal
deleted
inserted
replaced
778 RPointerArray<CMdEObject> mdeObjectArray; |
778 RPointerArray<CMdEObject> mdeObjectArray; |
779 CleanupClosePushL( mdeObjectArray ); |
779 CleanupClosePushL( mdeObjectArray ); |
780 |
780 |
781 TTimeIntervalSeconds timeOffsetSeconds = User::UTCOffset(); |
781 TTimeIntervalSeconds timeOffsetSeconds = User::UTCOffset(); |
782 |
782 |
783 TInt fastHarvestPlaceholderCount = 0; |
|
784 |
|
785 TInt endindex( iPHArray.Count() ); |
783 TInt endindex( iPHArray.Count() ); |
786 for( TInt i = 0; i < endindex; i++ ) |
784 for( TInt i = 0; i < endindex; i++ ) |
787 { |
785 { |
788 CHarvesterData* hd = iPHArray[i]; |
786 CHarvesterData* hd = iPHArray[i]; |
789 |
787 |
844 i--; |
842 i--; |
845 endindex--; |
843 endindex--; |
846 iHarvesterEventManager->DecreaseItemCountL( EHEObserverTypeMMC, 1 ); |
844 iHarvesterEventManager->DecreaseItemCountL( EHEObserverTypeMMC, 1 ); |
847 CleanupStack::PopAndDestroy( entry ); |
845 CleanupStack::PopAndDestroy( entry ); |
848 CleanupStack::PopAndDestroy( phData ); |
846 CleanupStack::PopAndDestroy( phData ); |
|
847 CleanupStack::PopAndDestroy( mdeObject ); |
849 continue; |
848 continue; |
850 } |
849 } |
851 phData->SetUri( uri ); |
850 phData->SetUri( uri ); |
852 phData->SetModified( entry->iModified ); |
851 phData->SetModified( entry->iModified ); |
853 phData->SetFileSize( entry->iSize ); |
852 phData->SetFileSize( entry->iSize ); |
870 hd = NULL; |
869 hd = NULL; |
871 iPHArray.Remove( i ); |
870 iPHArray.Remove( i ); |
872 i--; |
871 i--; |
873 endindex--; |
872 endindex--; |
874 iHarvesterEventManager->DecreaseItemCountL( EHEObserverTypeMMC, 1 ); |
873 iHarvesterEventManager->DecreaseItemCountL( EHEObserverTypeMMC, 1 ); |
|
874 CleanupStack::PopAndDestroy( mdeObject ); |
875 continue; |
875 continue; |
876 } |
876 } |
877 CleanupStack::PushL( phData ); |
877 CleanupStack::PushL( phData ); |
878 } |
878 } |
879 |
879 |
944 hd->SetEventType( EHarvesterEdit ); |
944 hd->SetEventType( EHarvesterEdit ); |
945 |
945 |
946 // skip |
946 // skip |
947 if( hd->TakeSnapshot() ) |
947 if( hd->TakeSnapshot() ) |
948 { |
948 { |
949 fastHarvestPlaceholderCount++; |
|
950 hd->SetObjectType( EFastHarvest ); |
949 hd->SetObjectType( EFastHarvest ); |
951 } |
950 } |
952 else |
951 else |
953 { |
952 { |
954 hd->SetClientData( NULL ); |
953 hd->SetClientData( NULL ); |
981 { |
980 { |
982 // If some error occures, retry |
981 // If some error occures, retry |
983 iMdESession->AddObjectsL( mdeObjectArray ); |
982 iMdESession->AddObjectsL( mdeObjectArray ); |
984 } |
983 } |
985 |
984 |
986 const TInt eventObjectCount = objectCount - fastHarvestPlaceholderCount; |
985 iHarvesterEventManager->IncreaseItemCount( EHEObserverTypePlaceholder, |
987 |
986 objectCount ); |
988 if( eventObjectCount > 0 ) |
987 iHarvesterEventManager->SendEventL( EHEObserverTypePlaceholder, EHEStateStarted, |
989 { |
988 iHarvesterEventManager->ItemCount( EHEObserverTypePlaceholder ) ); |
990 iHarvesterEventManager->IncreaseItemCount( EHEObserverTypePlaceholder, |
|
991 eventObjectCount ); |
|
992 iHarvesterEventManager->SendEventL( EHEObserverTypePlaceholder, EHEStateStarted, |
|
993 iHarvesterEventManager->ItemCount( EHEObserverTypePlaceholder ) ); |
|
994 } |
|
995 |
989 |
996 #ifdef _DEBUG |
990 #ifdef _DEBUG |
997 for (TInt i = 0; i < objectCount; ++i) |
991 for (TInt i = 0; i < objectCount; ++i) |
998 { |
992 { |
999 CMdEObject* mdeObject = mdeObjectArray[i]; |
993 CMdEObject* mdeObject = mdeObjectArray[i]; |
2455 void CHarvesterAO::BootPartialRestoreScanL() |
2449 void CHarvesterAO::BootPartialRestoreScanL() |
2456 { |
2450 { |
2457 // check if partial restore was done before last boot |
2451 // check if partial restore was done before last boot |
2458 TBool partialRestore = iRestoreWatcher->Register(); |
2452 TBool partialRestore = iRestoreWatcher->Register(); |
2459 |
2453 |
2460 #ifdef __WINSCW__ |
2454 #if defined(__WINSCW__) || defined(FF_PLATFORM_SIMULATOR) |
2461 partialRestore = ETrue; |
2455 partialRestore = ETrue; |
2462 #endif |
2456 #endif |
2463 |
2457 |
2464 if ( !partialRestore ) |
2458 if ( !partialRestore ) |
2465 { |
2459 { |