author | Sebastian Brannstrom <sebastianb@symbian.org> |
Sat, 16 Oct 2010 15:36:19 +0100 | |
branch | 3rded |
changeset 275 | e2c3225833c3 |
parent 175 | cd124c4eb6b9 |
child 343 | 9c56bf585696 |
permissions | -rw-r--r-- |
2 | 1 |
/* |
2 |
* Copyright (c) 2007-2010 Sebastian Brannstrom, Lars Persson, EmbedDev AB |
|
3 |
* |
|
4 |
* All rights reserved. |
|
5 |
* This component and the accompanying materials are made available |
|
6 |
* under the terms of the License "Eclipse Public License v1.0" |
|
7 |
* which accompanies this distribution, and is available |
|
8 |
* at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
9 |
* |
|
10 |
* Initial Contributors: |
|
11 |
* EmbedDev AB - initial contribution. |
|
12 |
* |
|
13 |
* Contributors: |
|
14 |
* |
|
15 |
* Description: |
|
16 |
* |
|
17 |
*/ |
|
18 |
||
19 |
#ifndef PODCASTSHOWSVIEWH |
|
20 |
#define PODCASTSHOWSVIEWH |
|
21 |
||
22 |
#include <aknview.h> |
|
23 |
#include <aknlists.h> |
|
24 |
#include <eiklbo.h> |
|
25 |
#include "ShowEngine.h" |
|
26 |
#include "FeedEngine.h" |
|
27 |
#include "PodcastModel.h" |
|
28 |
#include "Podcast.hrh" |
|
29 |
#include "PodcastListView.h" |
|
30 |
||
31 |
class CPodcastShowsView : public CPodcastListView, public MEikListBoxObserver, |
|
49
43e204e6ae2e
Fix for accidental merge regressions. Text fixes for tool tip and settings.
teknolog
parents:
32
diff
changeset
|
32 |
public MFeedEngineObserver, public MShowEngineObserver |
2 | 33 |
{ |
34 |
public: |
|
35 |
static CPodcastShowsView* NewL(CPodcastModel& aPodcastModel); |
|
36 |
static CPodcastShowsView* NewLC(CPodcastModel& aPodcastModel); |
|
37 |
~CPodcastShowsView(); |
|
13 | 38 |
|
2 | 39 |
protected: |
40 |
void ConstructL(); |
|
41 |
CPodcastShowsView(CPodcastModel& aPodcastModel); |
|
42 |
||
43 |
/** |
|
44 |
* Returns views id, intended for overriding by sub classes. |
|
45 |
* @return id for this view. |
|
46 |
*/ |
|
47 |
TUid Id() const; |
|
48 |
||
49 |
/** |
|
50 |
* Handles a view activation and passes the message of type |
|
51 |
* @c aCustomMessageId. This function is intended for overriding by |
|
52 |
* sub classes. This function is called by @c AknViewActivatedL(). |
|
53 |
* @param aPrevViewId Specifies the view previously active. |
|
54 |
* @param aCustomMessageId Specifies the message type. |
|
55 |
* @param aCustomMessage The activation message. |
|
56 |
*/ |
|
57 |
void DoActivateL(const TVwsViewId& aPrevViewId, |
|
58 |
TUid aCustomMessageId, |
|
59 |
const TDesC8& aCustomMessage); |
|
60 |
||
61 |
/** |
|
62 |
* View deactivation function intended for overriding by sub classes. |
|
63 |
* This function is called by @c AknViewDeactivated(). |
|
64 |
*/ |
|
65 |
void DoDeactivate(); |
|
66 |
||
67 |
void UpdateListboxItemsL(); |
|
68 |
||
69 |
// From // MEikListBoxObserverClass |
|
70 |
void HandleListBoxEventL(CEikListBox* aListBox, TListBoxEvent aEventType); |
|
71 |
// From showengine observer |
|
72 |
void ShowListUpdatedL(); |
|
73 |
void ShowDownloadUpdatedL(TInt aBytesOfCurrentDownload, TInt aBytesTotal); |
|
74 |
void DownloadQueueUpdatedL(TInt aDownloadingShows, TInt aQueuedShows); |
|
75 |
void ShowDownloadFinishedL(TUint aShowUid, TInt aError) ; |
|
76 |
// from MFeedEngineObserver |
|
77 |
void FeedDownloadStartedL(TFeedState aState,TUint aFeedUid); |
|
78 |
void FeedDownloadFinishedL(TFeedState aState,TUint aFeedUid, TInt aError); |
|
79 |
void FeedUpdateAllCompleteL(TFeedState aState); |
|
7 | 80 |
void OpmlParsingComplete(TInt /*aError*/, TUint /*aNumFeedsImported*/) {} |
2 | 81 |
|
82 |
/** |
|
83 |
* Command handling function intended for overriding by sub classes. |
|
84 |
* Default implementation is empty. |
|
85 |
* @param aCommand ID of the command to respond to. |
|
86 |
*/ |
|
87 |
void HandleCommandL(TInt aCommand); |
|
88 |
TKeyResponse OfferKeyEventL(const TKeyEvent& aKeyEvent,TEventCode aType); |
|
89 |
||
90 |
void UpdateFeedUpdateStateL(); |
|
91 |
void UpdateShowItemL(TUint aUid, TInt aSizeDownloaded); |
|
92 |
void UpdateShowItemDataL(CShowInfo* aShowInfo,TInt aIndex, TInt aSizeDownloaded = KErrNotFound); |
|
93 |
void DynInitMenuPaneL(TInt aResourceId,CEikMenuPane* aMenuPane); |
|
94 |
void FormatShowInfoListBoxItemL(CShowInfo& aShowInfo, TInt aSizeDownloaded = 0); |
|
60 | 95 |
void GetShowIcons(CShowInfo* aShowInfo, TInt& aIconIndex); |
96 |
void CreateIconsL(); |
|
2 | 97 |
|
98 |
private: |
|
99 |
void DisplayShowInfoDialogL(); |
|
35
66c5303f3610
A ton of CodeScanner fixes (high issues) - but not all
Brendan Donegan <brendand@symbian.org>
parents:
13
diff
changeset
|
100 |
void HandleSetShowPlayedL(TBool aPlayed); |
66c5303f3610
A ton of CodeScanner fixes (high issues) - but not all
Brendan Donegan <brendand@symbian.org>
parents:
13
diff
changeset
|
101 |
void HandleDeleteShowL(); |
60 | 102 |
void ImageOperationCompleteL(TInt /* aError */, TUint /* aHandle */, CPodcastModel& /* aPodcastModel */) {} |
5 | 103 |
void HandleSetShowPlayed(TBool aPlayed); |
104 |
void HandleDeleteShow(); |
|
2 | 105 |
void UpdateViewTitleL(); |
106 |
void GetShowErrorText(TDes &aErrorMessage, TInt aErrorCode); |
|
107 |
||
60 | 108 |
protected: |
2 | 109 |
|
110 |
CPodcastModel& iPodcastModel; |
|
111 |
TBool iProgressAdded; |
|
112 |
TInt iLastImageHandlerError; |
|
113 |
TBool iSetTitlebarImage; |
|
114 |
}; |
|
115 |
||
116 |
#endif // PODCASTSHOWSVIEWH |
|
117 |
||
118 |