equal
deleted
inserted
replaced
140 } |
140 } |
141 } |
141 } |
142 |
142 |
143 void CPodcastQueueView::UpdateListboxItemsL() |
143 void CPodcastQueueView::UpdateListboxItemsL() |
144 { |
144 { |
145 if (iListContainer->IsVisible()) |
145 if (iListContainer->IsVisible() && !iDontUpdateList) |
146 { |
146 { |
147 TListItemProperties itemProps; |
147 TListItemProperties itemProps; |
148 TInt len = 0; |
148 TInt len = 0; |
149 |
149 |
150 iPodcastModel.GetShowsDownloadingL(); |
150 iPodcastModel.GetShowsDownloadingL(); |
234 case EPodcastRemoveDownload: |
234 case EPodcastRemoveDownload: |
235 { |
235 { |
236 TInt index = iListContainer->Listbox()->CurrentItemIndex(); |
236 TInt index = iListContainer->Listbox()->CurrentItemIndex(); |
237 if (index >= 0 && index < iPodcastModel.ActiveShowList().Count()) |
237 if (index >= 0 && index < iPodcastModel.ActiveShowList().Count()) |
238 { |
238 { |
|
239 // this is an ugly hack to prevent UpdateListboxItemsL from being |
|
240 // triggered from the show engine, which causes focus to jump |
|
241 // around in an ugly fashion |
|
242 iDontUpdateList = ETrue; |
239 TRAP_IGNORE(iPodcastModel.ShowEngine().RemoveDownloadL(iPodcastModel.ActiveShowList()[index]->Uid())); |
243 TRAP_IGNORE(iPodcastModel.ShowEngine().RemoveDownloadL(iPodcastModel.ActiveShowList()[index]->Uid())); |
|
244 iDontUpdateList = EFalse; |
|
245 } |
|
246 UpdateListboxItemsL(); |
|
247 if (index > 0) |
|
248 { |
|
249 iListContainer->Listbox()->SetCurrentItemIndex(index - 1); |
240 } |
250 } |
241 } |
251 } |
242 break; |
252 break; |
243 case EPodcastMoveDownloadUp: |
253 case EPodcastMoveDownloadUp: |
244 { |
254 { |