application/src/PodcastFeedView.cpp
changeset 94 8d36b7608232
parent 93 bbf5c5204844
child 96 a8538f50e2ba
--- a/application/src/PodcastFeedView.cpp	Wed Mar 31 14:50:33 2010 +0200
+++ b/application/src/PodcastFeedView.cpp	Wed Mar 31 16:06:20 2010 +0200
@@ -127,6 +127,7 @@
 	delete iNeverUpdated;
 	delete iStylusPopupMenu;
 	delete iUpdater;
+	iFeedIdForIconArray.Close();
     }
 
 void CPodcastFeedView::UpdateItemL(TInt aIndex)
@@ -378,8 +379,8 @@
 			}
 		}
 	CArrayPtr<CGulIcon>* icons = iListContainer->Listbox()->ItemDrawer()->FormattedCellData()->IconArray();
-
-	if(aFeedInfo.FeedIcon() != NULL && 
+	iconIndex = iFeedIdForIconArray.Find(aFeedInfo.Uid());
+	if(iconIndex == KErrNotFound && aFeedInfo.FeedIcon() != NULL && 
 			aFeedInfo.FeedIcon()->SizeInPixels().iHeight > 0 &&
 			aFeedInfo.FeedIcon()->SizeInPixels().iWidth > 0)
 		{
@@ -389,14 +390,14 @@
 		CleanupStack::PushL(bmpCopy);
 		bmpCopy->Duplicate(aFeedInfo.FeedIcon()->Handle());
 		icons->AppendL( CGulIcon::NewL(bmpCopy, NULL));
+		iFeedIdForIconArray.Append(aFeedInfo.Uid());
 		CleanupStack::Pop(bmpCopy);			
 		iconIndex = icons->Count()-1;
-		}
+		}	
 	else 
 		{
-		iconIndex = 0;
-		}
-
+		iconIndex++;
+		}	
 
 	if (unplayedShows.Length() > 0) {
 		unplayedShows.Insert(0,_L(", "));