homesync/contentmanager/cmserver/cmstoremanager/src/cmsmfilemngr.cpp
changeset 32 3785f754ee62
parent 0 7f85d04be362
equal deleted inserted replaced
27:03808033c9a2 32:3785f754ee62
   277         {
   277         {
   278         CCmStoreRule* storeRule = CCmStoreRule::NewLC();    
   278         CCmStoreRule* storeRule = CCmStoreRule::NewLC();    
   279         iDBManager->PrepareQueryCmdL(EStoreRuleQuery);
   279         iDBManager->PrepareQueryCmdL(EStoreRuleQuery);
   280         storeRule->SetNameL( *array[i] );        
   280         storeRule->SetNameL( *array[i] );        
   281         iDBManager->QueryStoreRuleL( storeRule );
   281         iDBManager->QueryStoreRuleL( storeRule );
   282         iRuleArray.Append( storeRule );
   282         iRuleArray.AppendL( storeRule );
   283         CleanupStack::Pop(storeRule);
   283         CleanupStack::Pop(storeRule);
   284         }
   284         }
   285     array.ResetAndDestroy();
   285     array.ResetAndDestroy();
   286     CleanupStack::PopAndDestroy( &array );
   286     CleanupStack::PopAndDestroy( &array );
   287     }
   287     }
   509                 // To find if Uuid of ms has been in iMsIds.
   509                 // To find if Uuid of ms has been in iMsIds.
   510                 for( TInt l = 0 ; l < iMsIds.Count(); l++ )
   510                 for( TInt l = 0 ; l < iMsIds.Count(); l++ )
   511                     {
   511                     {
   512                     if( KErrNone == ms.Compare( *iMsIds[l]->iUuid ) )
   512                     if( KErrNone == ms.Compare( *iMsIds[l]->iUuid ) )
   513                         {
   513                         {
   514                         aIds.InsertInOrder( iMsIds[l]->iId );
   514                         aIds.InsertInOrderL( iMsIds[l]->iId );
   515                         // End loop    
   515                         // End loop    
   516                     	l = iMsIds.Count();  
   516                     	l = iMsIds.Count();  
   517                         }
   517                         }
   518                     }
   518                     }
   519                 }
   519                 }
   541             id = iDBManager->QueryMediaServerId( mediaServer );
   541             id = iDBManager->QueryMediaServerId( mediaServer );
   542             if( KErrNone < id && KErrNotFound == tempIds.Find(id) )
   542             if( KErrNone < id && KErrNotFound == tempIds.Find(id) )
   543                 {
   543                 {
   544                 HBufC8* uuid = mediaServer.AllocLC();
   544                 HBufC8* uuid = mediaServer.AllocLC();
   545                 CCmSmMsInfo* msInfo = CCmSmMsInfo::NewLC( *uuid, id );
   545                 CCmSmMsInfo* msInfo = CCmSmMsInfo::NewLC( *uuid, id );
   546                 tempIds.Append(id);
   546                 tempIds.AppendL(id);
   547                 iMsIds.Append(msInfo);                
   547                 iMsIds.AppendL(msInfo);                
   548                 CleanupStack::Pop( msInfo );
   548                 CleanupStack::Pop( msInfo );
   549                 CleanupStack::PopAndDestroy( uuid );
   549                 CleanupStack::PopAndDestroy( uuid );
   550                 }
   550                 }
   551             }
   551             }
   552         }
   552         }
   612             if( index < statusValues.Count() )
   612             if( index < statusValues.Count() )
   613                 {
   613                 {
   614                 if( itemOnSelectedList &&
   614                 if( itemOnSelectedList &&
   615                     ECmStored != statusValues[ index ] )
   615                     ECmStored != statusValues[ index ] )
   616                     {
   616                     {
   617                     aItemIds.Append( i );
   617                     aItemIds.AppendL( i );
   618                     }                
   618                     }                
   619                 }            
   619                 }            
   620             }
   620             }
   621         }
   621         }
   622     }
   622     }