440 |
440 |
441 CategoriesL().ResetVideoCountersL(); |
441 CategoriesL().ResetVideoCountersL(); |
442 CategoriesL().UpdateCategoriesL( *iCache->iVideoList, 0 ); |
442 CategoriesL().UpdateCategoriesL( *iCache->iVideoList, 0 ); |
443 CategoriesL().UpdateCategoriesNewVideoNamesL(); |
443 CategoriesL().UpdateCategoriesNewVideoNamesL(); |
444 |
444 |
445 #ifdef VCX_ALBUMS |
445 #ifdef VCX_ALBUMS |
|
446 // Adds changed album indexes to Albums().iChangedAlbums. |
|
447 // AlbumsL().UpdateChangedAlbumsL() will update the changed ones and add events. |
|
448 AlbumsL().VideosAddedOrRemovedFromCacheL( aId ); |
|
449 |
446 AlbumsL().RemoveAlbumsL( aId ); |
450 AlbumsL().RemoveAlbumsL( aId ); |
447 #endif |
451 #endif |
448 } |
452 } |
449 break; |
453 break; |
450 |
454 |
468 // video condition and only video objects are added to cache. Items which were detected |
472 // video condition and only video objects are added to cache. Items which were detected |
469 // to not be videos are added to nonVideoIds. |
473 // to not be videos are added to nonVideoIds. |
470 iCache->AddVideosFromMdsL( aId, videoListFetchingWasCancelled, |
474 iCache->AddVideosFromMdsL( aId, videoListFetchingWasCancelled, |
471 &nonVideoIds, EFalse /* dont update categories*/ ); |
475 &nonVideoIds, EFalse /* dont update categories*/ ); |
472 |
476 |
473 CategoriesL().ResetVideoCountersL(); |
477 if ( aId.Count() ) |
474 CategoriesL().UpdateCategoriesL( *iCache->iVideoList, 0 ); |
478 { |
475 CategoriesL().UpdateCategoriesNewVideoNamesL(); |
479 CategoriesL().ResetVideoCountersL(); |
|
480 CategoriesL().UpdateCategoriesL( *iCache->iVideoList, 0 ); |
|
481 CategoriesL().UpdateCategoriesNewVideoNamesL(); |
|
482 |
|
483 #ifdef VCX_ALBUMS |
|
484 // Adds changed album indexes to Albums().iChangedAlbums. |
|
485 // AlbumsL().UpdateChangedAlbumsL() will update the changed ones and add events. |
|
486 AlbumsL().VideosAddedOrRemovedFromCacheL( aId ); |
|
487 #endif |
|
488 } |
476 |
489 |
477 #ifdef VCX_ALBUMS |
490 #ifdef VCX_ALBUMS |
478 #if 0 //TODO: do this if we want to support albums which are being added by someone else than My Videos Collection |
491 #if 0 //TODO: do this if we want to support albums which are being added by someone else than My Videos Collection |
479 |
492 |
480 //After the call nonVideoIds will contain only items which were actually added |
493 //After the call nonVideoIds will contain only items which were actually added |
481 //to albums. |
494 //to albums. |
482 AlbumsL().AddAlbumsFromMdsL( nonVideoIds ); |
495 AlbumsL().AddAlbumsFromMdsL( nonVideoIds ); |
|
496 #else |
|
497 nonVideoIds.Reset(); |
483 #endif |
498 #endif |
484 #endif |
499 #endif |
485 |
500 |
486 if ( videoListFetchingWasCancelled ) |
501 if ( videoListFetchingWasCancelled ) |
487 { |
502 { |
564 { |
579 { |
565 TRAP_IGNORE( iMessageList->AddEventL( |
580 TRAP_IGNORE( iMessageList->AddEventL( |
566 TMPXItemId( nonVideoIds[i], KVcxMvcMediaTypeAlbum ), aEvent ) ); |
581 TMPXItemId( nonVideoIds[i], KVcxMvcMediaTypeAlbum ), aEvent ) ); |
567 } |
582 } |
568 |
583 |
569 iAlbums->UpdateChangedAlbumsL(); |
584 AlbumsL().UpdateChangedAlbumsL(); |
570 #endif |
585 #endif |
571 |
586 |
572 CleanupStack::PopAndDestroy( &nonVideoIds ); |
587 CleanupStack::PopAndDestroy( &nonVideoIds ); |
573 iMessageList->SendL(); |
588 iMessageList->SendL(); |
574 } |
589 } |