62
|
1 |
/*
|
|
2 |
* Copyright (c) 2002 - 2007 Nokia Corporation and/or its subsidiary(-ies).
|
|
3 |
* All rights reserved.
|
|
4 |
* This component and the accompanying materials are made available
|
|
5 |
* under the terms of "Eclipse Public License v1.0"
|
|
6 |
* which accompanies this distribution, and is available
|
|
7 |
* at the URL "http://www.eclipse.org/legal/epl-v10.html".
|
|
8 |
*
|
|
9 |
* Initial Contributors:
|
|
10 |
* Nokia Corporation - initial contribution.
|
|
11 |
*
|
|
12 |
* Contributors:
|
|
13 |
*
|
|
14 |
* Description: MpxCollectionTest test module.
|
|
15 |
*
|
|
16 |
*/
|
|
17 |
|
|
18 |
#ifndef PATHOPTIONISREMOTE_H
|
|
19 |
#define PATHOPTIONISREMOTE_H
|
|
20 |
|
|
21 |
// INCLUDES
|
|
22 |
#include "testmenuview.h"
|
|
23 |
|
|
24 |
// MACROS
|
|
25 |
|
|
26 |
// FORWARD DECLARATIONS
|
|
27 |
class MMPXCollectionUtility;
|
|
28 |
class CMPXCollectionPath;
|
|
29 |
class CStifLogger;
|
|
30 |
|
|
31 |
// DATA TYPES
|
|
32 |
_LIT(KTxtPathOptionIsRemote, "PathOptionIsRemote");
|
|
33 |
|
|
34 |
// CLASS DECLARATION
|
|
35 |
class CPathOptionIsRemote : public CTestMenuView,
|
|
36 |
public MMPXCollectionObserver
|
|
37 |
{
|
|
38 |
public:
|
|
39 |
/**
|
|
40 |
* Two-phased constructor
|
|
41 |
* @return object of CConsoleMain
|
|
42 |
*/
|
|
43 |
static CPathOptionIsRemote* NewL(CConsoleMain* aConsoleMain,
|
|
44 |
CTestBaseView* aParent,
|
|
45 |
const TDesC& aName,
|
|
46 |
CStifLogger* aLogger,
|
|
47 |
CMPXCollectionPath* aPath);
|
|
48 |
|
|
49 |
/**
|
|
50 |
* Destructor of CConsoleMain
|
|
51 |
*/
|
|
52 |
virtual ~CPathOptionIsRemote();
|
|
53 |
|
|
54 |
public: //From base classes
|
|
55 |
/**
|
|
56 |
* From CTestBaseView
|
|
57 |
* Initialize the view before display view
|
|
58 |
*/
|
|
59 |
void InitializeViewL();
|
|
60 |
|
|
61 |
/**
|
|
62 |
* From CTestBaseView
|
|
63 |
* Cleanup the view before deactivate/destroy view
|
|
64 |
*/
|
|
65 |
void CleanupViewL();
|
|
66 |
|
|
67 |
/**
|
|
68 |
* From CTestBaseView
|
|
69 |
* Handle number key press
|
|
70 |
*/
|
|
71 |
void HandleNumKeyL();
|
|
72 |
|
|
73 |
/**
|
|
74 |
* From CTestBaseView
|
|
75 |
* Handle left key press
|
|
76 |
*/
|
|
77 |
void HandleLeftKeyL();
|
|
78 |
|
|
79 |
/**
|
|
80 |
* From CTestBaseView
|
|
81 |
* Handle right/enter key press
|
|
82 |
*/
|
|
83 |
void HandleRightKeyL();
|
|
84 |
|
|
85 |
/**
|
|
86 |
* From MMPXCollectionObserver
|
|
87 |
* Handle extended media properties
|
|
88 |
* @param aMedia media
|
|
89 |
* @param aError error code
|
|
90 |
*/
|
|
91 |
void HandleCollectionMediaL(
|
|
92 |
const CMPXMedia& aMedia,
|
|
93 |
TInt aError);
|
|
94 |
|
|
95 |
/**
|
|
96 |
* From MMPXCollectionObserver
|
|
97 |
* Handle collection message
|
|
98 |
* @param aMessage collection message
|
|
99 |
*/
|
|
100 |
void HandleCollectionMessageL(const TMPXCollectionMessage& aMessage);
|
|
101 |
|
|
102 |
/**
|
|
103 |
* From MMPXCollectionObserver
|
|
104 |
* Handles the collection entries being opened. Typically called
|
|
105 |
* when client has Open()'d a folder
|
|
106 |
*
|
|
107 |
* @param aEntries collection entries opened
|
|
108 |
* @param aIndex focused entry
|
|
109 |
* @param aComplete ETrue no more entries. EFalse more entries
|
|
110 |
* expected
|
|
111 |
* @param aError error code
|
|
112 |
*/
|
|
113 |
void HandleOpenL(const CMPXMedia& aEntries,
|
|
114 |
TInt aIndex,TBool aComplete,TInt aError);
|
|
115 |
|
|
116 |
/**
|
|
117 |
* From MMPXCollectionObserver
|
|
118 |
* Handles the item being opened. Typically called
|
|
119 |
* when client has Open()'d an item. Client typically responds by
|
|
120 |
* 'playing' the item via the playlist
|
|
121 |
*
|
|
122 |
* @param aPlaylist collection playlist, owner ship is transfered
|
|
123 |
* @param aError error code
|
|
124 |
*/
|
|
125 |
void HandleOpenL(const CMPXCollectionPlaylist& aPlaylist,TInt aError);
|
|
126 |
|
|
127 |
private:
|
|
128 |
/**
|
|
129 |
* C++ default constructor.
|
|
130 |
*/
|
|
131 |
CPathOptionIsRemote(CConsoleMain* aConsoleMain,
|
|
132 |
CTestBaseView* aParent,
|
|
133 |
const TDesC& aName,
|
|
134 |
CStifLogger* aLogger);
|
|
135 |
|
|
136 |
/**
|
|
137 |
* the second phase constructor ConstructL to safely construct things
|
|
138 |
* that can leave
|
|
139 |
*/
|
|
140 |
void ConstructL(CMPXCollectionPath* aPath);
|
|
141 |
|
|
142 |
/**
|
|
143 |
* Output a string to RDebug, Stiflogger, and Screen
|
|
144 |
*/
|
|
145 |
void OutputStringL(const TDesC& aStr);
|
|
146 |
|
|
147 |
private: //data
|
|
148 |
MMPXCollectionUtility* iCollectionUtility; //owns
|
|
149 |
CStifLogger* iLogger; //uses
|
|
150 |
CMPXCollectionPath* iCollectionPath;
|
|
151 |
};
|
|
152 |
|
|
153 |
|
|
154 |
|
|
155 |
#endif //PATHOPTIONISREMOTE_H
|
|
156 |
|