--- a/application/data/PodcastFeedView.ra Wed Oct 13 23:58:25 2010 +0100
+++ b/application/data/PodcastFeedView.ra Sat Oct 16 18:04:09 2010 +0100
@@ -56,6 +56,24 @@
{
command = EAknSoftkeyExit;
txt = STRING_r_exit_cmd;
+ },
+ MENU_ITEM
+ {
+ txt = STRING_r_view_edit_feed_cmd_short;
+ command = EPodcastEditFeed;
+ flags = EEikMenuItemSpecific;
+ },
+ MENU_ITEM
+ {
+ txt = STRING_r_view_delete_feed_cmd_short;
+ command = EPodcastDeleteFeed;
+ flags = EEikMenuItemSpecific;
+ },
+ MENU_ITEM
+ {
+ txt = STRING_r_update_feed_short_cmd;
+ command = EPodcastUpdateFeed;
+ flags = EEikMenuItemSpecific;
}
};
}
@@ -249,28 +267,6 @@
};
}
-RESOURCE STYLUS_POPUP_MENU r_feedview_popup_menu
- {
- items =
- {
- STYLUS_POPUP_MENU_ITEM
- {
- txt = STRING_r_view_edit_feed_cmd_short;
- command = EPodcastEditFeed;
- },
- STYLUS_POPUP_MENU_ITEM
- {
- txt = STRING_r_view_delete_feed_cmd_short;
- command = EPodcastDeleteFeed;
- },
- STYLUS_POPUP_MENU_ITEM
- {
- txt = STRING_r_update_feed_short_cmd;
- command = EPodcastUpdateFeed;
- }
- };
- }
-
RESOURCE ARRAY r_feedview_add_url_or_search_array
{
items =
--- a/application/data/PodcastQueueView.ra Wed Oct 13 23:58:25 2010 +0100
+++ b/application/data/PodcastQueueView.ra Sat Oct 16 18:04:09 2010 +0100
@@ -49,6 +49,24 @@
{
command = EAknSoftkeyExit;
txt = STRING_r_exit_cmd;
+ },
+ MENU_ITEM
+ {
+ txt = STRING_r_view_remove_download_short_cmd;
+ command = EPodcastRemoveDownload;
+ flags = EEikMenuItemSpecific;
+ },
+ MENU_ITEM
+ {
+ txt = STRING_r_view_move_up_short_cmd;
+ command = EPodcastMoveDownloadUp;
+ flags = EEikMenuItemSpecific;
+ },
+ MENU_ITEM
+ {
+ txt = STRING_r_view_move_down_short_cmd;
+ command = EPodcastMoveDownloadDown;
+ flags = EEikMenuItemSpecific;
}
};
}
@@ -115,25 +133,3 @@
}
};
}
-
-RESOURCE STYLUS_POPUP_MENU r_queueview_popup_menu
- {
- items =
- {
- STYLUS_POPUP_MENU_ITEM
- {
- txt = STRING_r_view_remove_download_short_cmd;
- command = EPodcastRemoveDownload;
- },
- STYLUS_POPUP_MENU_ITEM
- {
- txt = STRING_r_view_move_up_short_cmd;
- command = EPodcastMoveDownloadUp;
- },
- STYLUS_POPUP_MENU_ITEM
- {
- txt = STRING_r_view_move_down_short_cmd;
- command = EPodcastMoveDownloadDown;
- }
- };
- }
--- a/application/data/PodcastShowsView.ra Wed Oct 13 23:58:25 2010 +0100
+++ b/application/data/PodcastShowsView.ra Sat Oct 16 18:04:09 2010 +0100
@@ -54,6 +54,36 @@
{
command = EAknSoftkeyExit;
txt = STRING_r_exit_cmd;
+ },
+ MENU_ITEM
+ {
+ txt = STRING_r_view_show_info_cmd;
+ command = EPodcastShowInfo;
+ flags = EEikMenuItemSpecific;
+ },
+ MENU_ITEM
+ {
+ txt = STRING_r_view_mark_as_unplayed_cmd_short;
+ command = EPodcastMarkAsUnplayed;
+ flags = EEikMenuItemSpecific;
+ },
+ MENU_ITEM
+ {
+ txt = STRING_r_view_mark_as_played_cmd_short;
+ command = EPodcastMarkAsPlayed;
+ flags = EEikMenuItemSpecific;
+ },
+ MENU_ITEM
+ {
+ txt = STRING_r_view_download_show_cmd;
+ command = EPodcastDownloadShow;
+ flags = EEikMenuItemSpecific;
+ },
+ MENU_ITEM
+ {
+ txt = STRING_r_view_delete_show_cmd;
+ command = EPodcastDeleteShow;
+ flags = EEikMenuItemSpecific;
}
};
}
@@ -122,38 +152,6 @@
};
}
-RESOURCE STYLUS_POPUP_MENU r_showview_popup_menu
- {
- items =
- {
- STYLUS_POPUP_MENU_ITEM
- {
- txt = STRING_r_view_show_info_cmd;
- command = EPodcastShowInfo;
- }
- ,STYLUS_POPUP_MENU_ITEM
- {
- txt = STRING_r_view_mark_as_unplayed_cmd_short;
- command = EPodcastMarkAsUnplayed;
- },
- STYLUS_POPUP_MENU_ITEM
- {
- txt = STRING_r_view_mark_as_played_cmd_short;
- command = EPodcastMarkAsPlayed;
- },
- STYLUS_POPUP_MENU_ITEM
- {
- txt = STRING_r_view_download_show_cmd;
- command = EPodcastDownloadShow;
- },
- STYLUS_POPUP_MENU_ITEM
- {
- txt = STRING_r_view_delete_show_cmd;
- command = EPodcastDeleteShow;
- }
- };
- }
-
RESOURCE DIALOG r_show_info_note
{
flags = EAknDialogGenericQueryFlags | EEikDialogFlagNoBorder | EEikDialogFlagNoShadow;
--- a/application/inc/PodcastFeedView.h Wed Oct 13 23:58:25 2010 +0100
+++ b/application/inc/PodcastFeedView.h Sat Oct 16 18:04:09 2010 +0100
@@ -98,8 +98,6 @@
// from MImageHandlerCallback
void ImageOperationCompleteL(TInt aError, TUint aHandle, CPodcastModel& aPodcastModel);
- void HandleLongTapEventL( const TPoint& aPenEventLocation, const TPoint& aPenEventScreenLocation);
-
private:
void FormatFeedInfoListBoxItemL(CFeedInfo& aFeedInfo, TBool aIsUpdating = EFalse);
void HandleAddFeedL();
--- a/application/inc/PodcastListView.h Wed Oct 13 23:58:25 2010 +0100
+++ b/application/inc/PodcastListView.h Sat Oct 16 18:04:09 2010 +0100
@@ -57,31 +57,23 @@
void HandleResourceChange(TInt aType);
virtual TKeyResponse OfferKeyEventL(const TKeyEvent& aKeyEvent,TEventCode aType);
void SetKeyEventListener(MKeyEventListener *aKeyEventListener);
- void SetPointerListener(MPointerListener *aPointerListener);
CEikFormattedCellListBox* Listbox();
void ScrollToVisible();
void Draw(const TRect& aRect) const;
- void SetLongTapDetectedL(TBool aLongTapDetected);
-
CEikFormattedCellListBox * iListbox;
protected:
TTypeUid::Ptr MopSupplyObject( TTypeUid aId );
- virtual void HandlePointerEventL(const TPointerEvent& aPointerEvent);
private:
MKeyEventListener* iKeyEventListener;
- MPointerListener* iPointerListener;
CAknsBasicBackgroundControlContext* iBgContext;
- TBool iLongTapDetected;
-
};
class CPodcastListView : public CAknView, public MAknToolbarObserver,
-public MPointerListener, public MAknLongTapDetectorCallBack,
public MProgressDialogCallback, public MKeyEventListener
{
public:
@@ -140,19 +132,13 @@
void CloseToolbarExtension();
void ShowWaitDialogL(TDesC &aWaitText);
void CloseWaitDialog();
-
- // From MAknLongTapDetectorCallBack
- virtual void HandleLongTapEventL( const TPoint& aPenEventLocation, const TPoint& aPenEventScreenLocation );
-
+
// from MProgressDialogCallback
void DialogDismissedL(TInt /*aButtonId*/) {}
// from MKeyEventListener
virtual TKeyResponse OfferKeyEventL(const TKeyEvent& aKeyEvent,TEventCode aType);
- // from MPointerListener
- void PointerEventL(const TPointerEvent& aPointerEvent);
-
protected:
CPodcastListContainer* iListContainer;
/** Previous activated view */
@@ -167,10 +153,7 @@
TBuf<1024> iListboxFormatbuffer;
CAknToolbar *iToolbar;
- CAknStylusPopUpMenu* iStylusPopupMenu;
- CAknLongTapDetector* iLongTapDetector;
CAknWaitDialog *iWaitDialog;
-
};
#endif // PODCASTBASEVIEWH
--- a/application/inc/PodcastQueueView.h Wed Oct 13 23:58:25 2010 +0100
+++ b/application/inc/PodcastQueueView.h Sat Oct 16 18:04:09 2010 +0100
@@ -79,8 +79,6 @@
TKeyResponse OfferKeyEventL(const TKeyEvent& aKeyEvent,TEventCode aType);
void DynInitMenuPaneL(TInt aResourceId,CEikMenuPane* aMenuPane);
- virtual void HandleLongTapEventL( const TPoint& aPenEventLocation, const TPoint& aPenEventScreenLocation);
-
private:
TBool iDontUpdateList;
};
--- a/application/inc/PodcastShowsView.h Wed Oct 13 23:58:25 2010 +0100
+++ b/application/inc/PodcastShowsView.h Sat Oct 16 18:04:09 2010 +0100
@@ -96,7 +96,6 @@
void DynInitMenuPaneL(TInt aResourceId,CEikMenuPane* aMenuPane);
void FormatShowInfoListBoxItemL(CShowInfo& aShowInfo, TInt aSizeDownloaded = 0);
- virtual void HandleLongTapEventL( const TPoint& aPenEventLocation, const TPoint& aPenEventScreenLocation);
void GetShowIcons(CShowInfo* aShowInfo, TInt& aIconIndex);
void CreateIconsL();
--- a/application/inc/buildno.h Wed Oct 13 23:58:25 2010 +0100
+++ b/application/inc/buildno.h Sat Oct 16 18:04:09 2010 +0100
@@ -1,2 +1,2 @@
// Build number generated by increment_buildno.py, do not edit manually
-#define BUILD_NO 2
\ No newline at end of file
+#define BUILD_NO 3
\ No newline at end of file
--- a/application/sis/buildno.txt Wed Oct 13 23:58:25 2010 +0100
+++ b/application/sis/buildno.txt Sat Oct 16 18:04:09 2010 +0100
@@ -1,1 +1,1 @@
-2
\ No newline at end of file
+3
\ No newline at end of file
--- a/application/sis/podcatcher_udeb.pkg Wed Oct 13 23:58:25 2010 +0100
+++ b/application/sis/podcatcher_udeb.pkg Sat Oct 16 18:04:09 2010 +0100
@@ -1,7 +1,7 @@
&EN,SP
:"Symbian Foundation"
%{"Podcatcher","Podcatcher"}
-#{"Podcatcher","Podcatcher"},(0xA0009D00), 1, 00, 2, TYPE=SA
+#{"Podcatcher","Podcatcher"},(0xA0009D00), 1, 00, 3, TYPE=SA
;Supports Symbian^3
[0x20022E6D], 0, 0, 0, {"Series60ProductID","Series60ProductID"}
Binary file application/sis/podcatcher_udeb.sis has changed
Binary file application/sis/podcatcher_udeb_signed.sis has changed
--- a/application/sis/podcatcher_urel.pkg Wed Oct 13 23:58:25 2010 +0100
+++ b/application/sis/podcatcher_urel.pkg Sat Oct 16 18:04:09 2010 +0100
@@ -1,7 +1,7 @@
&EN,SP
:"Symbian Foundation"
%{"Podcatcher","Podcatcher"}
-#{"Podcatcher","Podcatcher"},(0xA0009D00), 0, 90, 2, TYPE=SA
+#{"Podcatcher","Podcatcher"},(0xA0009D00), 0, 90, 3, TYPE=SA
;Supports Symbian^3
[0x20022E6D], 0, 0, 0, {"Series60ProductID","Series60ProductID"}
--- a/application/src/PodcastAppui.cpp Wed Oct 13 23:58:25 2010 +0100
+++ b/application/src/PodcastAppui.cpp Sat Oct 16 18:04:09 2010 +0100
@@ -43,7 +43,8 @@
void CPodcastAppUi::ConstructL()
{
DP("CPodcastAppUi::ConstructL() BEGIN");
- BaseConstructL(CAknAppUi::EAknEnableSkin | CAknAppUi::EAknEnableMSK | CAknAppUi::EAknSingleClickCompatible);
+ BaseConstructL(CAknAppUi::EAknEnableSkin | CAknAppUi::EAknEnableMSK |
+ CAknAppUi::EAknSingleClickCompatible | CAknAppUi::EAknTouchCompatible );
iPodcastModel->ConnectionEngine().AddObserver(this);
--- a/application/src/PodcastFeedView.cpp Wed Oct 13 23:58:25 2010 +0100
+++ b/application/src/PodcastFeedView.cpp Sat Oct 16 18:04:09 2010 +0100
@@ -107,12 +107,6 @@
iListContainer->Listbox()->SetListBoxObserver(this);
- iStylusPopupMenu = CAknStylusPopUpMenu::NewL( this , TPoint(0,0));
- TResourceReader reader;
- iCoeEnv->CreateResourceReaderLC(reader,R_FEEDVIEW_POPUP_MENU);
- iStylusPopupMenu->ConstructFromResourceL(reader);
- CleanupStack::PopAndDestroy();
-
iUpdater = CPodcastFeedViewUpdater::NewL(*this);
DP("CPodcastFeedView::ConstructL END");
}
@@ -122,7 +116,6 @@
iPodcastModel.FeedEngine().RemoveObserver(this);
delete iFeedsFormat;
delete iNeverUpdated;
- delete iStylusPopupMenu;
delete iUpdater;
iFeedIdForIconArray.Close();
}
@@ -545,7 +538,6 @@
break;
}
- iListContainer->SetLongTapDetectedL(EFalse); // in case we got here by long tapping
UpdateToolbar();
DP("CPodcastFeedView::HandleCommandL END");
}
@@ -956,24 +948,6 @@
TRAP_IGNORE(((CPodcastAppUi*)AppUi())->GetErrorTextL(aErrorMessage,aErrorCode));
}
-void CPodcastFeedView::HandleLongTapEventL( const TPoint& aPenEventLocation, const TPoint& /* aPenEventScreenLocation */)
-{
- DP("CPodcastListView::HandleLongTapEventL BEGIN");
-
- iListContainer->SetLongTapDetectedL(ETrue);
-
- const TInt KListboxDefaultHeight = 19; // for some reason it returns 19 for an empty listbox in S^1
- TInt lbHeight = iListContainer->Listbox()->CalcHeightBasedOnNumOfItems(
- iListContainer->Listbox()->Model()->NumberOfItems()) - KListboxDefaultHeight;
-
- if(iStylusPopupMenu && aPenEventLocation.iY < lbHeight)
- {
- iStylusPopupMenu->ShowMenu();
- iStylusPopupMenu->SetPosition(aPenEventLocation);
- }
- DP("CPodcastListView::HandleLongTapEventL END");
-}
-
TBool CPodcastFeedView::ViewingShows()
{
return iViewingShows;
--- a/application/src/PodcastListView.cpp Wed Oct 13 23:58:25 2010 +0100
+++ b/application/src/PodcastListView.cpp Sat Oct 16 18:04:09 2010 +0100
@@ -97,20 +97,6 @@
}
}
-void CPodcastListContainer::SetLongTapDetectedL(TBool aLongTapDetected)
- {
- DP("CPodcastListContainer::SetLongTapDetectedL BEGIN");
- iLongTapDetected = aLongTapDetected;
-
- if (aLongTapDetected == EFalse)
- {
- TPointerEvent event;
- event.iType = TPointerEvent::EButton1Up;
- //CCoeControl::HandlePointerEventL(event);
- }
- DP("CPodcastListContainer::SetLongTapDetectedL END");
- }
-
void CPodcastListContainer::HandleResourceChange(TInt aType)
{
switch( aType )
@@ -167,25 +153,6 @@
return CCoeControl::MopSupplyObject(aId);
}
-void CPodcastListContainer::HandlePointerEventL(const TPointerEvent& aPointerEvent)
- {
- if (iPointerListener)
- iPointerListener->PointerEventL(aPointerEvent);
-
- // Call base class HandlePointerEventL() if not a long tap
- if (!iLongTapDetected)
- {
- CCoeControl::HandlePointerEventL(aPointerEvent);
- }
- }
-
-
-void CPodcastListContainer::SetPointerListener(MPointerListener *aPointerListener)
- {
- iPointerListener = aPointerListener;
- }
-
-
CPodcastListView::CPodcastListView()
{
}
@@ -206,8 +173,6 @@
iToolbar->SetToolbarObserver(this);
}
- iLongTapDetector = CAknLongTapDetector::NewL(this);
- iListContainer->SetPointerListener(this);
iListContainer->SetKeyEventListener(this);
DP("CPodcastListView::ConstructL END");
@@ -242,7 +207,6 @@
}
delete iItemArray;
- delete iLongTapDetector;
iItemIdArray.Close();
}
@@ -376,33 +340,6 @@
}
}
-void CPodcastListView::PointerEventL(const TPointerEvent& aPointerEvent)
- {
- //DP1("CPodcastListView::PointerEventL, iType=%d", aPointerEvent.iType);
- // Pass the pointer event to Long tap detector component
- iLongTapDetector->PointerEventL(aPointerEvent);
- }
-
-
-void CPodcastListView::HandleLongTapEventL( const TPoint& aPenEventLocation, const TPoint& /* aPenEventScreenLocation */)
-{
- DP("CPodcastListView::HandleLongTapEventL BEGIN");
- iListContainer->SetLongTapDetectedL(ETrue);
-
- const TInt KListboxDefaultHeight = 19; // for some reason it returns 19 for an empty listbox in S^1
- TInt lbHeight = iListContainer->Listbox()->CalcHeightBasedOnNumOfItems(
- iListContainer->Listbox()->Model()->NumberOfItems()) - KListboxDefaultHeight;
-
- if(iStylusPopupMenu && aPenEventLocation.iY < lbHeight)
- {
- iStylusPopupMenu->ShowMenu();
- iStylusPopupMenu->SetPosition(aPenEventLocation);
- }
-
- DP("CPodcastListView::HandleLongTapEventL END");
-}
-
-
void CPodcastListView::DynInitToolbarL (TInt /*aResourceId*/, CAknToolbar * /*aToolbar*/)
{
}
--- a/application/src/PodcastQueueView.cpp Wed Oct 13 23:58:25 2010 +0100
+++ b/application/src/PodcastQueueView.cpp Sat Oct 16 18:04:09 2010 +0100
@@ -66,13 +66,6 @@
iPodcastModel.FeedEngine().AddObserver(this);
iPodcastModel.ShowEngine().AddObserver(this);
-
- iStylusPopupMenu = CAknStylusPopUpMenu::NewL( this , TPoint(0,0));
- TResourceReader reader;
- iCoeEnv->CreateResourceReaderLC(reader,R_QUEUEVIEW_POPUP_MENU);
- iStylusPopupMenu->ConstructFromResourceL(reader);
-
- CleanupStack::PopAndDestroy();
SetEmptyTextL(R_PODCAST_EMPTY_QUEUE);
}
@@ -109,9 +102,6 @@
{
iPodcastModel.ShowEngine().RemoveObserver(this);
iPodcastModel.FeedEngine().RemoveObserver(this);
-
- if(iStylusPopupMenu)
- delete iStylusPopupMenu, iStylusPopupMenu = NULL;
}
@@ -328,7 +318,6 @@
CPodcastListView::HandleCommandL(aCommand);
break;
}
- iListContainer->SetLongTapDetectedL(EFalse); // in case we got here by long tapping
UpdateToolbar();
}
@@ -337,6 +326,22 @@
if(aResourceId == R_PODCAST_SHOWSVIEW_MENU)
{
aMenuPane->SetItemDimmed(EPodcastMarkAllPlayed, ETrue);
+
+ TBool dimDown = (iListContainer->Listbox()->CurrentItemIndex() >= iPodcastModel.ActiveShowList().Count() - 1 ?
+ ETrue : EFalse);
+ TBool dimUp = (iListContainer->Listbox()->CurrentItemIndex() <= 0 ?
+ ETrue : EFalse);
+
+ TInt index = iListContainer->Listbox()->CurrentItemIndex();
+
+ if (index >= 0 && index < iPodcastModel.ActiveShowList().Count())
+ {
+ CShowInfo* info = iPodcastModel.ActiveShowList()[index];
+
+ aMenuPane->SetItemDimmed(EPodcastMoveDownloadDown, dimDown);
+ aMenuPane->SetItemDimmed(EPodcastMoveDownloadUp, dimUp);
+
+ }
}
}
@@ -360,29 +365,3 @@
toolbar->SetItemDimmed(EPodcastRemoveDownload, itemCnt == 0, ETrue);
}
}
-
-void CPodcastQueueView::HandleLongTapEventL( const TPoint& aPenEventLocation, const TPoint& /* aPenEventScreenLocation */)
-{
- DP("CPodcastQueueView::HandleLongTapEventL BEGIN");
- iListContainer->SetLongTapDetectedL(ETrue);
-
- const TInt KListboxDefaultHeight = 19; // for some reason it returns 19 for an empty listbox in S^1
- TInt lbHeight = iListContainer->Listbox()->CalcHeightBasedOnNumOfItems(
- iListContainer->Listbox()->Model()->NumberOfItems()) - KListboxDefaultHeight;
-
- if(iStylusPopupMenu && aPenEventLocation.iY < lbHeight)
- {
- TBool dimDown = (iListContainer->Listbox()->CurrentItemIndex() >= iPodcastModel.ActiveShowList().Count() - 1 ?
- ETrue : EFalse);
- TBool dimUp = (iListContainer->Listbox()->CurrentItemIndex() <= 0 ?
- ETrue : EFalse);
-
- iStylusPopupMenu->SetItemDimmed(EPodcastMoveDownloadDown, dimDown);
- iStylusPopupMenu->SetItemDimmed(EPodcastMoveDownloadUp, dimUp);
-
- iStylusPopupMenu->ShowMenu();
- iStylusPopupMenu->SetPosition(aPenEventLocation);
- }
-
- DP("CPodcastQueueView::HandleLongTapEventL END");
-}
--- a/application/src/PodcastSearchView.cpp Wed Oct 13 23:58:25 2010 +0100
+++ b/application/src/PodcastSearchView.cpp Sat Oct 16 18:04:09 2010 +0100
@@ -95,12 +95,6 @@
{
iPodcastModel.FeedEngine().RemoveObserver(this);
- if(iLongTapDetector)
- delete iLongTapDetector, iLongTapDetector = NULL;
-
- if(iStylusPopupMenu)
- delete iStylusPopupMenu, iStylusPopupMenu = NULL;
-
}
TUid CPodcastSearchView::Id() const
--- a/application/src/PodcastShowsView.cpp Wed Oct 13 23:58:25 2010 +0100
+++ b/application/src/PodcastShowsView.cpp Sat Oct 16 18:04:09 2010 +0100
@@ -114,13 +114,6 @@
iPodcastModel.FeedEngine().AddObserver(this);
iPodcastModel.ShowEngine().AddObserver(this);
-
- iStylusPopupMenu = CAknStylusPopUpMenu::NewL( this , TPoint(0,0));
- TResourceReader reader;
- iCoeEnv->CreateResourceReaderLC(reader,R_SHOWVIEW_POPUP_MENU);
- iStylusPopupMenu->ConstructFromResourceL(reader);
-
- CleanupStack::PopAndDestroy();
}
void CPodcastShowsView::CreateIconsL()
@@ -198,9 +191,6 @@
{
iPodcastModel.ShowEngine().RemoveObserver(this);
iPodcastModel.FeedEngine().RemoveObserver(this);
-
- if(iStylusPopupMenu)
- delete iStylusPopupMenu, iStylusPopupMenu = NULL;
}
@@ -629,7 +619,6 @@
CPodcastListView::HandleCommandL(aCommand);
break;
}
- iListContainer->SetLongTapDetectedL(EFalse);
UpdateToolbar();
}
@@ -640,6 +629,23 @@
{
TBool updatingState = iPodcastModel.FeedEngine().ClientState() != EIdle && iPodcastModel.FeedEngine().ActiveClientUid() == iPodcastModel.ActiveFeedInfo()->Uid();
aMenuPane->SetItemDimmed(EPodcastMarkAllPlayed, updatingState);
+
+ TInt index = iListContainer->Listbox()->CurrentItemIndex();
+
+ if (index >= 0 && index < iPodcastModel.ActiveShowList().Count())
+ {
+ CShowInfo* info = iPodcastModel.ActiveShowList()[index];
+
+ TBool hideDownloadShowCmd = info->DownloadState() != ENotDownloaded;
+ TBool hideDeleteShowCmd = info->DownloadState() != EDownloaded;
+ TBool hideMarkOld = info->PlayState() == EPlayed;
+
+ aMenuPane->SetItemDimmed(EPodcastMarkAsPlayed, hideMarkOld);
+ aMenuPane->SetItemDimmed(EPodcastMarkAsUnplayed, !hideMarkOld);
+
+ aMenuPane->SetItemDimmed(EPodcastDownloadShow, hideDownloadShowCmd);
+ aMenuPane->SetItemDimmed(EPodcastDeleteShow, hideDeleteShowCmd);
+ }
}
}
@@ -681,39 +687,6 @@
}
}
-void CPodcastShowsView::HandleLongTapEventL( const TPoint& aPenEventLocation, const TPoint& /* aPenEventScreenLocation */)
-{
- DP("CPodcastShowsView::HandleLongTapEventL BEGIN");
-
- iListContainer->SetLongTapDetectedL(ETrue);
-
- const TInt KListboxDefaultHeight = 19; // for some reason it returns 19 for an empty listbox in S^1
- TInt lbHeight = iListContainer->Listbox()->CalcHeightBasedOnNumOfItems(
- iListContainer->Listbox()->Model()->NumberOfItems()) - KListboxDefaultHeight;
-
- if(iStylusPopupMenu && aPenEventLocation.iY < lbHeight)
- {
- TInt index = iListContainer->Listbox()->CurrentItemIndex();
- if (index >= 0 && index < iPodcastModel.ActiveShowList().Count())
- {
- CShowInfo *info = iPodcastModel.ActiveShowList()[index];
- TBool hideDownloadShowCmd = info->DownloadState() != ENotDownloaded;
- TBool hideDeleteShowCmd = info->DownloadState() != EDownloaded;
- TBool hideMarkOld = info->PlayState() == EPlayed;
-
- iStylusPopupMenu->SetItemDimmed(EPodcastMarkAsPlayed, hideMarkOld);
- iStylusPopupMenu->SetItemDimmed(EPodcastMarkAsUnplayed, !hideMarkOld);
-
- iStylusPopupMenu->SetItemDimmed(EPodcastDownloadShow, hideDownloadShowCmd);
- iStylusPopupMenu->SetItemDimmed(EPodcastDeleteShow, hideDeleteShowCmd);
- }
-
- iStylusPopupMenu->ShowMenu();
- iStylusPopupMenu->SetPosition(aPenEventLocation);
- }
- DP("CPodcastShowsView::HandleLongTapEventL END");
-}
-
void CPodcastShowsView::HandleSetShowPlayedL(TBool aPlayed)
{