author | Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com> |
Wed, 13 Oct 2010 14:28:40 +0300 | |
branch | RCL_3 |
changeset 66 | 1f1dad4af8f8 |
parent 53 | 3de6c4cf6b67 |
permissions | -rw-r--r-- |
53 | 1 |
/* |
2 |
* Copyright (c) 2006 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: MPX common playback view implementation |
|
66
1f1dad4af8f8
Revision: 201039
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
53
diff
changeset
|
15 |
* Version : %version: e003sa33#41.1.6.1.1.1.13 % << Don't touch! Updated by Synergy at check-out. |
53 | 16 |
* |
17 |
*/ |
|
18 |
||
19 |
||
20 |
||
21 |
#ifndef CMPXCOMMONPLAYBACKVIEWIMP_H |
|
22 |
#define CMPXCOMMONPLAYBACKVIEWIMP_H |
|
23 |
||
24 |
||
25 |
// INCLUDES |
|
26 |
#include <aknview.h> |
|
27 |
#include <AknServerApp.h> |
|
28 |
#include <AknProgressDialog.h> // MProgressDialogCallback |
|
29 |
#include <mpxplaybackobserver.h> |
|
30 |
#include <mpxcollectionobserver.h> |
|
31 |
#include <mpxcollectionuihelper.h> |
|
32 |
#include <mpxcollectionuihelperobserver.h> |
|
33 |
#include <mpxpskeyobserver.h> // MMPXPSKeyObserver |
|
34 |
#include <mpxcenrepobserver.h> // MMPXCenRepObserver |
|
35 |
#include <mpxviewactivationobserver.h> // MMPXViewActivationObserver |
|
36 |
||
37 |
#include "mpxlayoutswitchobserver.h" |
|
38 |
#include "mpxplaybackframeworkdefs.h" // TMPXPlaybackPlayerType |
|
39 |
||
40 |
#include "../../../inc/musicplayerbldvariant.hrh" |
|
41 |
#include <tvoutconfig.h> |
|
42 |
||
43 |
// FORWARD DECLARATIONS |
|
44 |
class CMPXCommonPlaybackViewContainer; |
|
45 |
class MMPXPlaybackUtility; |
|
46 |
class CMPXAlbumArtUtil; |
|
47 |
class CMPXCommonUiHelper; |
|
48 |
class MMPXViewUtility; |
|
49 |
class CMPXCollectionPlaylist; |
|
50 |
class CMPXCommonPlaybackViewLayout; |
|
51 |
class MMPXPlayerManager; |
|
52 |
class MMPXCollectionUtility; |
|
53 |
class CMPXPSKeyWatcher; |
|
54 |
class CMPXCenRepWatcher; |
|
55 |
#ifdef IAD_INCLUDE_BACKSTEPPING |
|
56 |
class MMPXBackSteppingUtility; |
|
57 |
#endif // IAD_INCLUDE_BACKSTEPPING |
|
58 |
class CAiwServiceHandler; |
|
59 |
class CMediaRecognizer; |
|
60 |
class CAiwGenericParamList; |
|
61 |
#ifdef IAD_INCLUDE_UPNP |
|
62 |
class CUpnpCopyCommand; |
|
63 |
#endif |
|
64 |
// CLASS DECLARATION |
|
65 |
||
66 |
/** |
|
67 |
* MPX playback view. |
|
68 |
* |
|
69 |
* @lib mpxplaybackview.lib |
|
70 |
* @since S60 v3.0 |
|
71 |
*/ |
|
72 |
class CMPXCommonPlaybackViewImp : public CAknView, |
|
73 |
public MMPXPlaybackObserver, |
|
74 |
public MMPXPlaybackCallback, |
|
75 |
public MAknServerAppExitObserver, |
|
76 |
public MMPXLayoutSwitchObserver, |
|
77 |
public MCoeViewActivationObserver, |
|
78 |
public MMPXCHelperObserver, |
|
79 |
public MMPXPSKeyObserver, |
|
80 |
public MMPXCenRepObserver, |
|
81 |
public MProgressDialogCallback, |
|
82 |
public MMPXViewActivationObserver, |
|
83 |
public MMPXCollectionObserver |
|
84 |
{ |
|
85 |
public: |
|
86 |
enum TCommandSender |
|
87 |
{ |
|
88 |
ECsUnknown, |
|
89 |
ECsMediaKey, |
|
90 |
ECsRenderer |
|
91 |
}; |
|
92 |
public: |
|
93 |
/** |
|
94 |
* Destructor. |
|
95 |
*/ |
|
96 |
IMPORT_C virtual ~CMPXCommonPlaybackViewImp(); |
|
97 |
||
98 |
protected: |
|
99 |
/** |
|
100 |
* By default Symbian 2nd phase constructor is private. |
|
101 |
*/ |
|
102 |
IMPORT_C virtual void ConstructL(); |
|
103 |
||
104 |
/** |
|
105 |
* Updates playback view. |
|
106 |
*/ |
|
107 |
IMPORT_C virtual void UpdateViewL(); |
|
108 |
||
109 |
/** |
|
110 |
* Updates track info field. |
|
111 |
* |
|
112 |
* @param aMedia Media's properties. If NULL, default info will |
|
113 |
* be shown. |
|
114 |
*/ |
|
115 |
IMPORT_C virtual void UpdateTrackInfoL( |
|
116 |
const CMPXMedia* aMedia ); |
|
117 |
||
118 |
/** |
|
119 |
* Update current playback state. |
|
120 |
* |
|
121 |
* @param aPlaybackState Current playback state. |
|
122 |
*/ |
|
123 |
IMPORT_C virtual void UpdatePlaybackStateL( |
|
124 |
TMPXPlaybackState aPlaybackState ); |
|
125 |
||
126 |
/** |
|
127 |
* Updates track's playback position. |
|
128 |
* |
|
129 |
* @param aPos, New playback postions in seconds |
|
130 |
* @param aDuration, Track duration in seconds |
|
131 |
*/ |
|
132 |
IMPORT_C virtual void UpdateTrackPlaybackPositionL( |
|
133 |
TInt aPos, |
|
134 |
TInt aDuration ); |
|
135 |
||
136 |
/** |
|
137 |
* Updates track's album art. |
|
138 |
* |
|
139 |
* @param aMedia Media's properties. If NULL, default album art |
|
140 |
* will be shown. |
|
141 |
*/ |
|
142 |
IMPORT_C virtual void UpdateAlbumArtL( |
|
143 |
const CMPXMedia* aMedia ); |
|
144 |
||
145 |
/** |
|
146 |
* Updates track position in playlist field. |
|
147 |
*/ |
|
148 |
IMPORT_C virtual void UpdateTrackPosInPlaylistL(); |
|
149 |
||
150 |
/** |
|
151 |
* Updates download state label. |
|
152 |
*/ |
|
153 |
IMPORT_C virtual void UpdateDownloadStateLabelL(); |
|
154 |
||
155 |
/** |
|
156 |
* Updates the title pane |
|
157 |
*/ |
|
158 |
IMPORT_C virtual void UpdateTitlePaneL(); |
|
159 |
||
160 |
/** |
|
161 |
* Updates FM Transmitter Info |
|
162 |
*/ |
|
163 |
IMPORT_C virtual void UpdateFMTransmitterInfoL( |
|
164 |
TBool aForceUpdate = EFalse ); |
|
165 |
||
166 |
/** |
|
167 |
* Handle playback message |
|
168 |
* |
|
169 |
* @param aMsg playback message |
|
170 |
*/ |
|
171 |
IMPORT_C virtual void DoHandlePlaybackMessageL( |
|
172 |
const CMPXMessage& aMessage ); |
|
173 |
||
174 |
/** |
|
175 |
* Handle playback property |
|
176 |
* |
|
177 |
* @param aProperty the property |
|
178 |
* @param aValue the value of the property |
|
179 |
* @param aError error code |
|
180 |
*/ |
|
181 |
IMPORT_C virtual void DoHandlePropertyL( |
|
182 |
TMPXPlaybackProperty aProperty, |
|
183 |
TInt aValue, |
|
184 |
TInt aError ); |
|
185 |
||
186 |
/** |
|
187 |
* Handle media properties. |
|
188 |
* |
|
189 |
* @param aMedia media properties |
|
190 |
* @param aError error code |
|
191 |
*/ |
|
192 |
IMPORT_C virtual void DoHandleMediaL( |
|
193 |
const CMPXMedia& aMedia, |
|
194 |
TInt aError ); |
|
195 |
||
196 |
/** |
|
197 |
* Handle playback state changed. |
|
198 |
* |
|
199 |
* @param aState New Playback state |
|
200 |
* @param aData Extra data parameter, used for any extra information |
|
201 |
* along with the state change message |
|
202 |
*/ |
|
203 |
IMPORT_C virtual void DoHandleStateChangedL( |
|
204 |
TMPXPlaybackState aState, |
|
205 |
TInt aData ); |
|
206 |
||
207 |
/** |
|
208 |
* Get simple embedded mode. |
|
209 |
* |
|
210 |
* @return ETrue if the player is in the embedded mode (i.e. launched |
|
211 |
* from Browser or Message Centre). |
|
212 |
*/ |
|
213 |
IMPORT_C virtual TBool SimpleEmbeddedMode() const; |
|
214 |
||
215 |
/** |
|
216 |
* Get embedded status. |
|
217 |
* |
|
218 |
* @return ETrue if in embedded mode. Otherwise, EFalse. |
|
219 |
*/ |
|
220 |
IMPORT_C virtual TBool IsEmbedded() const; |
|
221 |
||
222 |
/** |
|
223 |
* Displays error notes. |
|
224 |
* |
|
225 |
* @param aError Error ID to be handled. |
|
226 |
*/ |
|
227 |
IMPORT_C virtual void HandleErrorL( TInt aError ); |
|
228 |
||
229 |
/** |
|
230 |
* Displays error note for when all tracks are invalid, |
|
231 |
* and goes back to collection list view |
|
232 |
*/ |
|
233 |
IMPORT_C virtual void HandleAllTracksInvalidL(); |
|
234 |
||
235 |
/** |
|
236 |
* Checks whether or not to skip to next track on an error |
|
237 |
* |
|
238 |
* @param aCurrentIndex Current index |
|
239 |
*/ |
|
240 |
IMPORT_C virtual void SkipOnErrorL( TInt aCurrentIndex, TInt aCount ); |
|
241 |
||
242 |
/** |
|
243 |
* Function to display information notes |
|
244 |
* |
|
245 |
* @param aResourceId Resource ID of the text string. |
|
246 |
*/ |
|
247 |
IMPORT_C virtual void DisplayInfoNoteL( TInt aResourceId ); |
|
248 |
||
249 |
/** |
|
250 |
* Function to display confirmation notes |
|
251 |
* |
|
252 |
* @param aResourceId Resource ID of the text string. |
|
253 |
*/ |
|
254 |
IMPORT_C virtual void DisplayConfirmionNoteL( TInt aResourceId ); |
|
255 |
||
256 |
/** |
|
257 |
* Set process priority. |
|
258 |
*/ |
|
259 |
IMPORT_C virtual void SetProcessPriority(); |
|
260 |
||
261 |
/** |
|
262 |
* Launch equalizer dialog. |
|
263 |
*/ |
|
264 |
IMPORT_C virtual void LaunchEqualizerL(); |
|
265 |
||
266 |
/** |
|
267 |
* Launch Music Settings view. |
|
268 |
*/ |
|
269 |
IMPORT_C virtual void LaunchMusicSettingsL(); |
|
270 |
||
271 |
/** |
|
272 |
* Launch FM Transmitter |
|
273 |
*/ |
|
274 |
IMPORT_C virtual void LaunchFMTransmitterL(); |
|
275 |
||
276 |
/** |
|
277 |
* Request for the media object |
|
278 |
* aDrm Flag whether or not to request all DRM info as well |
|
279 |
*/ |
|
280 |
IMPORT_C virtual void RequestMediaL( TBool aDrm=EFalse ); |
|
281 |
||
282 |
/** |
|
283 |
* Prepare status pane for full-screen playback view. |
|
284 |
*/ |
|
285 |
void PrepareStatusPaneForPlaybackViewL(); |
|
286 |
||
287 |
/** |
|
288 |
* Restore status pane to it's normal state. |
|
289 |
*/ |
|
290 |
void PrepareStatusPaneForExitingViewL(); |
|
291 |
||
292 |
/** |
|
293 |
* Checks if UPnP AP is defined |
|
294 |
*/ |
|
295 |
IMPORT_C virtual TBool IsUpnpVisibleL(); |
|
296 |
||
297 |
/** |
|
298 |
* Displays the available players in the Play via submenu |
|
299 |
*/ |
|
300 |
IMPORT_C virtual void AddPlayersNamesToMenuL( CEikMenuPane& aMenuPane ); |
|
301 |
||
302 |
/** |
|
303 |
* Adds one player type to the Play via submenu |
|
304 |
* @param aMenuPane Menu pane |
|
305 |
* @param aCommandId Command id |
|
306 |
* @param aPlayerManager Playback Utility manager |
|
307 |
* @param aPlayerType Current player type (Local, Remote) |
|
308 |
* @param aMenuText Text to be added to the menu |
|
309 |
*/ |
|
310 |
IMPORT_C virtual void AddPlayerNameToMenuL( CEikMenuPane& aMenuPane, |
|
311 |
TInt aCommandId, |
|
312 |
MMPXPlayerManager& aPlayerManager, |
|
313 |
TMPXPlaybackPlayerType& aPlayerType, |
|
314 |
const TDesC& aMenuText = KNullDesC ); |
|
315 |
||
316 |
/** |
|
317 |
* Retrieves the current player name and type |
|
318 |
*/ |
|
319 |
IMPORT_C virtual void GetCurrentPlayerDetails(); |
|
320 |
||
321 |
/** |
|
322 |
* Selects a new player for audio playback |
|
323 |
*/ |
|
324 |
IMPORT_C virtual void SelectNewPlayerL( TInt aCommand ); |
|
325 |
||
326 |
/** |
|
327 |
* Adds current item to a saved playlist |
|
328 |
*/ |
|
329 |
IMPORT_C virtual void AddToSavedPlaylistL(); |
|
330 |
||
331 |
/** |
|
332 |
* Adds current item to a new playlist |
|
333 |
*/ |
|
334 |
IMPORT_C virtual void AddToNewPlaylistL(); |
|
335 |
||
336 |
/** |
|
337 |
* Prepares media for adding to a playlist |
|
338 |
* @return Media object for adding to playlist. Caller is |
|
339 |
* responsible for deleting and popping off cleanupstack |
|
340 |
*/ |
|
341 |
IMPORT_C virtual CMPXMedia* PrepareMediaForPlaylistLC( |
|
342 |
const CMPXMedia& aMedia ); |
|
343 |
||
344 |
/** |
|
345 |
* Check if the command is supported by the remote player |
|
346 |
* @return TBool whether the command is supported or not |
|
347 |
*/ |
|
348 |
IMPORT_C virtual TBool IsCommandSupportedL(); |
|
349 |
||
350 |
// from base class MProgressDialogCallback |
|
351 |
/** |
|
352 |
* From MProgressDialogCallback |
|
353 |
* Callback method |
|
354 |
* Get's called when a dialog is dismissed. |
|
355 |
*/ |
|
356 |
IMPORT_C virtual void DialogDismissedL( TInt aButtonId ); |
|
357 |
||
358 |
/* |
|
359 |
* From MMPXCHelperObserver |
|
360 |
* Handles the completion of any collection helper event. |
|
361 |
* |
|
362 |
* @param aOperation, operation completed |
|
363 |
* @param aErr. the error code |
|
364 |
* @param aArgument Argument returned from the operation |
|
365 |
*/ |
|
366 |
IMPORT_C virtual void HandleOperationCompleteL( TCHelperOperation aOperation, |
|
367 |
TInt aError, |
|
368 |
void* aArgument ); |
|
369 |
||
370 |
// from base class MMPXPlaybackObserver |
|
371 |
||
372 |
/** |
|
373 |
* From MMPXPlaybackObserver |
|
374 |
* Handle playback message |
|
375 |
* |
|
376 |
* @since 3.1 |
|
377 |
* @param aMessage Playback Message |
|
378 |
* @param aErr system error code. |
|
379 |
*/ |
|
380 |
IMPORT_C virtual void HandlePlaybackMessage( |
|
381 |
CMPXMessage* aMessage, TInt aError ); |
|
382 |
||
383 |
// from base class MMPXPlaybackCallback |
|
384 |
||
385 |
/** |
|
386 |
* From MMPXPlaybackCallback |
|
387 |
* Handle playback property |
|
388 |
* |
|
389 |
* @since 3.0 |
|
390 |
* @param aProperty the property |
|
391 |
* @param aValue the value of the property |
|
392 |
* @param aError error code |
|
393 |
*/ |
|
394 |
IMPORT_C virtual void HandlePropertyL( |
|
395 |
TMPXPlaybackProperty aProperty, |
|
396 |
TInt aValue, |
|
397 |
TInt aError ); |
|
398 |
||
399 |
/** |
|
400 |
* From MMPXPlaybackCallback |
|
401 |
* Method is called continously until aComplete=ETrue, signifying that |
|
402 |
* it is done and there will be no more callbacks |
|
403 |
* Only new items are passed each time |
|
404 |
* |
|
405 |
* @since 3.0 |
|
406 |
* @param aPlayer UID of the subplayer |
|
407 |
* @param aSubPlayers a list of sub players |
|
408 |
* @param aComplete ETrue no more sub players. EFalse more subplayer |
|
409 |
* expected |
|
410 |
* @param aError error code |
|
411 |
*/ |
|
412 |
IMPORT_C virtual void HandleSubPlayerNamesL( |
|
413 |
TUid aPlayer, |
|
414 |
const MDesCArray* aSubPlayers, |
|
415 |
TBool aComplete, |
|
416 |
TInt aError ); |
|
417 |
||
418 |
/** |
|
419 |
* From MMPXPlaybackCallback |
|
420 |
* Handle media properties |
|
421 |
* |
|
422 |
* @since 3.0 |
|
423 |
* @param aMedia media |
|
424 |
* @param aError error code |
|
425 |
*/ |
|
426 |
IMPORT_C virtual void HandleMediaL( |
|
427 |
const CMPXMedia& aMedia, |
|
428 |
TInt aError ); |
|
429 |
||
430 |
// from base class MMPXCollectionMediaObserver |
|
431 |
/** |
|
432 |
* Handle extended media properties |
|
433 |
* |
|
434 |
* @param aMedia media |
|
435 |
* @param aError error code |
|
436 |
*/ |
|
437 |
IMPORT_C virtual void HandleCollectionMediaL( |
|
438 |
const CMPXMedia& aMedia, |
|
439 |
TInt aError); |
|
440 |
||
441 |
||
442 |
// from base class CAknView |
|
443 |
||
444 |
/** |
|
445 |
* From CAknView |
|
446 |
* Command handling function. |
|
447 |
* |
|
448 |
* @since 3.0 |
|
449 |
* @param aCommand Command which is handled |
|
450 |
*/ |
|
451 |
IMPORT_C virtual void HandleCommandL( TInt aCommand ); |
|
452 |
||
453 |
/** |
|
454 |
* From CAknView |
|
455 |
* Processes user commands. |
|
456 |
* |
|
457 |
* @since 3.0 |
|
458 |
* @param aCommand ID of the command to respond to. |
|
459 |
*/ |
|
460 |
IMPORT_C virtual void ProcessCommandL( TInt aCommand ); |
|
461 |
||
462 |
/** |
|
463 |
* From CAknView |
|
464 |
* Event handler for status pane size changes. |
|
465 |
* |
|
466 |
* @since 3.0 |
|
467 |
*/ |
|
468 |
virtual void HandleStatusPaneSizeChange(); |
|
469 |
||
470 |
/** |
|
471 |
* From CAknView |
|
472 |
* Handles a view activation. |
|
473 |
* |
|
474 |
* @param aPrevViewId Specifies the view previously active. |
|
475 |
* @param aCustomMessageId Specifies the message type. |
|
476 |
* @param aCustomMessage The activation message. |
|
477 |
*/ |
|
478 |
IMPORT_C virtual void DoActivateL( |
|
479 |
const TVwsViewId& aPrevViewId, |
|
480 |
TUid aCustomMessageId, |
|
481 |
const TDesC8& aCustomMessage ); |
|
482 |
||
483 |
/** |
|
484 |
* From CAknView |
|
485 |
* View deactivation function. |
|
486 |
*/ |
|
487 |
IMPORT_C virtual void DoDeactivate(); |
|
488 |
||
489 |
/** |
|
490 |
* From CAknView |
|
491 |
* Foreground event handling function. |
|
492 |
* |
|
493 |
* @param aForeground Indicates the required focus state of the control. |
|
494 |
*/ |
|
495 |
IMPORT_C virtual void HandleForegroundEventL( TBool aForeground ); |
|
496 |
||
497 |
// from base class MEikMenuObserver |
|
498 |
||
499 |
/** |
|
500 |
* From MEikMenuObserver |
|
501 |
* Dynamically initialises a menu pane. |
|
502 |
* |
|
503 |
* @param aResourceId The ID of the menu pane. |
|
504 |
* @param aMenuPane The menu pane itself. |
|
505 |
*/ |
|
506 |
IMPORT_C void DynInitMenuPaneL( |
|
507 |
TInt aResourceId, |
|
508 |
CEikMenuPane* aMenuPane ); |
|
509 |
||
510 |
// from base class MMPXLayoutSwitchObserver |
|
511 |
||
512 |
/** |
|
513 |
* From MMPXLayoutSwitchObserver |
|
514 |
* Callback function when layout is changed. |
|
515 |
* |
|
516 |
* @since S60 v3.0 |
|
517 |
*/ |
|
518 |
IMPORT_C virtual void HandleLayoutChange(); |
|
519 |
||
520 |
// from base class MCoeViewDeactivationObserver |
|
521 |
||
522 |
/** |
|
523 |
* From MCoeViewDeactivationObserver |
|
524 |
* Handles the activation of the view aNewlyActivatedViewId before |
|
525 |
* the old view aViewIdToBeDeactivated is to be deactivated |
|
526 |
* |
|
527 |
* @param aNewlyActivatedViewId View ID that is newly activated. |
|
528 |
* @param aViewIdToBeDeactivated View ID to be deactivated. |
|
529 |
*/ |
|
530 |
IMPORT_C virtual void HandleViewActivation( |
|
531 |
const TVwsViewId& aNewlyActivatedViewId, |
|
532 |
const TVwsViewId& aViewIdToBeDeactivated ); |
|
533 |
||
534 |
// from base class MMPXViewActivationObserver |
|
535 |
||
536 |
/** |
|
537 |
* From MMPXViewActivationObserver |
|
538 |
* Handle view activation. |
|
539 |
* |
|
540 |
* @param aCurrentViewType Current view type Uid. |
|
541 |
* @param aPreviousViewType Previous view type Uid. |
|
542 |
*/ |
|
543 |
IMPORT_C virtual void HandleViewActivation( |
|
544 |
const TUid& aCurrentViewType, |
|
545 |
const TUid& aPreviousViewType ); |
|
546 |
||
547 |
/** |
|
548 |
* @see MMPXViewActivationObserver |
|
549 |
*/ |
|
550 |
IMPORT_C void HandleViewUpdate( |
|
551 |
TUid aViewUid, |
|
552 |
MMPXViewActivationObserver::TViewUpdateEvent aUpdateEvent, |
|
553 |
TBool aLoaded, |
|
554 |
TInt aData); |
|
555 |
||
556 |
// from base class MMPXPSKeyObserver |
|
557 |
||
558 |
/** |
|
559 |
* From MMPXPSKeyObserver |
|
560 |
* Handle PS event |
|
561 |
* |
|
562 |
* @param aUid The UID that identifies the property category |
|
563 |
* @param aKey The property sub-key |
|
564 |
*/ |
|
565 |
IMPORT_C virtual void HandlePSEvent( |
|
566 |
TUid aUid, |
|
567 |
TInt aKey ); |
|
568 |
||
569 |
// from base class MMPXCenRepObserver |
|
570 |
||
571 |
/** |
|
572 |
* From MMPXCenRepObserver |
|
573 |
* Handle a change in a setting value. |
|
574 |
* |
|
575 |
* @param aRepositoryUid Central repository UID containing the setting |
|
576 |
* @param aSettingId Id of the setting |
|
577 |
*/ |
|
578 |
IMPORT_C virtual void HandleSettingChange( |
|
579 |
const TUid& aRepositoryUid, |
|
580 |
TUint32 aSettingId ); |
|
581 |
||
582 |
// From base class MMPXCollectionObserver |
|
583 |
||
584 |
/** |
|
585 |
* From MMPXCollectionObserver |
|
586 |
*/ |
|
587 |
IMPORT_C virtual void HandleCollectionMessage(CMPXMessage* aMsg, TInt aErr); |
|
588 |
||
589 |
/** |
|
590 |
* From MMPXCollectionObserver |
|
591 |
*/ |
|
592 |
IMPORT_C virtual void HandleOpenL(const CMPXMedia& aEntries, TInt aIndex, |
|
593 |
TBool aComplete, TInt aError); |
|
594 |
||
595 |
/** |
|
596 |
* From MMPXCollectionObserver |
|
597 |
*/ |
|
598 |
IMPORT_C virtual void HandleOpenL(const CMPXCollectionPlaylist& aPlaylist,TInt aError); |
|
599 |
||
600 |
/** |
|
601 |
* From MMPXCollectionObserver |
|
602 |
*/ |
|
603 |
IMPORT_C virtual void HandleCommandComplete(CMPXCommand* aCommandResult, |
|
604 |
TInt aError); |
|
605 |
||
606 |
void FillAiwParametersL( CAiwGenericParamList& aParamList, TBool aSaved = EFalse ); |
|
607 |
/** |
|
608 |
* Updates the middle softkey display to a label or icon depending on the playback state |
|
609 |
* @param aMskId middle softkey command id |
|
610 |
*/ |
|
611 |
IMPORT_C void UpdateMiddleSoftKeyDisplayL(); |
|
612 |
/** |
|
613 |
* Updates the middle (play/pause) toolbar control key icon based on playback state |
|
614 |
*/ |
|
615 |
IMPORT_C void UpdateToolbarL(); |
|
616 |
||
617 |
/** |
|
618 |
* Launch Metadata Dialog to show the file details |
|
619 |
*/ |
|
620 |
IMPORT_C virtual void LaunchFileDetailsDialogL(); |
|
621 |
||
622 |
protected: |
|
623 |
static TInt DeferredAlbumArtExtractCallback( TAny* aPtr ); |
|
624 |
||
625 |
/** |
|
626 |
* Callback function for delayed view deactivation |
|
627 |
* @param aPtr pointer to self |
|
628 |
*/ |
|
629 |
static TInt DelayedExit( TAny* aPtr); |
|
630 |
||
631 |
private: |
|
632 |
/** |
|
633 |
* Handle playback error message |
|
634 |
* |
|
635 |
* @param aErr system error code. |
|
636 |
*/ |
|
637 |
void DoHandleErrorPlaybackMessageL( TInt aError ); |
|
638 |
||
639 |
/** |
|
640 |
* Handle collection message |
|
641 |
* |
|
642 |
* @param aMsg Message to handle. |
|
643 |
* @param aErr system error code. |
|
644 |
*/ |
|
645 |
void DoHandleCollectionMessageL( CMPXMessage* aMsg, TInt aErr ); |
|
646 |
||
647 |
/** |
|
648 |
* Callback function of timer to handle delayed error |
|
649 |
* @param aPtr pointer to self |
|
650 |
*/ |
|
651 |
static TInt HandleDelayedError( TAny* aPtr ); |
|
652 |
||
653 |
/** |
|
654 |
* Callback function of timer to handle TN request for custom size |
|
655 |
* @param aPtr pointer to self |
|
656 |
*/ |
|
657 |
static TInt HandleTNRequestForCustomSizeL( TAny* aPtr ); |
|
658 |
||
659 |
protected: // Data |
|
660 |
||
661 |
MMPXPlaybackUtility* iPlaybackUtility; // not own |
|
662 |
CMPXCommonPlaybackViewContainer* iContainer; // own |
|
663 |
||
664 |
CMPXAlbumArtUtil* iMPXUtility; // own |
|
665 |
CMPXMedia* iMedia; // own |
|
666 |
||
667 |
CMPXCommonUiHelper* iCommonUiHelper; // own |
|
668 |
||
669 |
CMPXPSKeyWatcher* iPSKeyWatcher; // own |
|
670 |
CMPXCenRepWatcher* iCRWatcher; // own |
|
671 |
TInt iFMTxFreqKHz; |
|
672 |
TInt iFmTxActivity; |
|
673 |
||
674 |
// View utility. |
|
675 |
MMPXViewUtility* iViewUtility; |
|
676 |
||
677 |
// Current playback states |
|
678 |
TInt iDuration; // in seconds |
|
679 |
TInt iPosition; // in seconds |
|
680 |
TMPXPlaybackState iPlaybackState; |
|
681 |
TInt iRandomMode; |
|
682 |
TInt iRepeatMode; |
|
683 |
||
684 |
TBool iEmbedded; |
|
685 |
TBool iSwitchingView; |
|
686 |
TBool iExitOptionHidden; |
|
687 |
||
688 |
// Feature flag for set as ringtone |
|
689 |
TBool iChangeRTForAllProfiles; |
|
690 |
||
691 |
// Error code to be handled at a later time |
|
692 |
TInt iDelayedError; |
|
693 |
||
694 |
CMPXCommonPlaybackViewLayout* iLayout; // owned |
|
695 |
||
696 |
//#ifdef __UPNP_FRAMEWORK_2_0_ |
|
697 |
RArray<TUid> iPlayersList; |
|
698 |
TMPXPlaybackPlayerType iCurrentPlayerType; |
|
699 |
HBufC* iSubPlayerName; |
|
700 |
//#endif //__UPNP_FRAMEWORK_2_0_ |
|
701 |
||
702 |
CAknProgressDialog* iWaitNote; |
|
703 |
||
704 |
MMPXCollectionUtility* iCollectionUtility; |
|
705 |
MMPXCollectionUiHelper* iCollectionUiHelper; |
|
706 |
||
707 |
TInt iStartPlaybackIndex; |
|
708 |
TInt iLastSkipDirection; |
|
709 |
TBool iSkipping; |
|
710 |
TInt iPreviousStatusPaneLayout; |
|
711 |
||
712 |
// Flag whether or not this was the last playback view activated, |
|
713 |
// used for error handling |
|
714 |
TBool iLastPBViewActivated; |
|
715 |
||
716 |
// Flag used for disable error msg pop up when usb event happens |
|
717 |
TBool iIgnoredByUsbEvent; |
|
718 |
||
719 |
// Flag that next view to be activated is a playback view type |
|
720 |
TBool iPBViewToBeActivated; |
|
721 |
||
722 |
// Flag that indicates Camese SuperDistribution Support |
|
723 |
TBool iCameseSuperDistSupport; |
|
724 |
||
725 |
// Flag that indicates a new item has been opened from Collection View. |
|
726 |
// Used for Camese Superdistribution error handling. |
|
727 |
TBool iNewItemOpened; |
|
728 |
||
729 |
CIdle* iIdle; |
|
730 |
||
731 |
// Idle for delayed exit |
|
732 |
CIdle* iDelayedExit; |
|
733 |
||
734 |
private: // Data |
|
735 |
||
736 |
TInt iResourceOffset; // must be freed |
|
737 |
||
738 |
TInt iFMTXResourceOffset; // must be freed |
|
739 |
||
740 |
#ifdef IAD_INCLUDE_BACKSTEPPING |
|
741 |
MMPXBackSteppingUtility* iBackSteppingUtility; |
|
742 |
#endif // BACKSTEPPING_INCLUDED |
|
743 |
||
744 |
CMPXMedia* iUserPlaylists; // owned |
|
745 |
TBool iKeySoundDisabled; |
|
746 |
TBool iDatabaseNotReady; |
|
747 |
CAiwServiceHandler* iServiceHandler; |
|
748 |
CMediaRecognizer* iMediaRecognizer; |
|
749 |
TInt iErrorAttachAssignMenu; |
|
750 |
TBool iSkipBtnPressed; |
|
751 |
||
752 |
//#ifdef __UPNP_FRAMEWORK_2_0_ |
|
753 |
TBool iUpnpFrameworkSupport; |
|
754 |
//#endif //__UPNP_FRAMEWORK_2_0_ |
|
755 |
||
756 |
TInt iLastDelayedErr; |
|
757 |
TInt iErrIndex; |
|
758 |
CPeriodic* iDelayedErrorTimer; |
|
759 |
// Indicate FF button pressed or not |
|
760 |
TBool iIsffButtonPressed; |
|
761 |
TBool iBacking; |
|
762 |
#ifdef IAD_INCLUDE_UPNP |
|
763 |
CUpnpCopyCommand* iUpnpCopyCommand; |
|
764 |
#endif |
|
765 |
TBool iUnsupportedNoteDisabled; |
|
766 |
HBufC* iOldUri; |
|
767 |
TInt iOldPosition; // in seconds |
|
768 |
TBool iIsTapped; |
|
769 |
TCommandSender iCommandSender; |
|
770 |
CTvOutConfig* iTvOutConfig; |
|
771 |
TSize iFullScreenImageSize; |
|
772 |
CPeriodic* iTNRequestTimer; |
|
773 |
}; |
|
774 |
||
775 |
#endif // CMPXCOMMONPLAYBACKVIEWIMP_H |
|
776 |
||
777 |
// End of File |