|
1 /* |
|
2 * Copyright (c) 2005 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: |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 #ifndef CAMMSTUNERPLAYER_H |
|
21 #define CAMMSTUNERPLAYER_H |
|
22 |
|
23 // INCLUDES |
|
24 #include <CMMAPlayer.h> |
|
25 #include "CAMMSTunerControl.h" |
|
26 |
|
27 #include <e32base.h> |
|
28 #include <tuner.h> |
|
29 |
|
30 |
|
31 // CLASS DECLARATION |
|
32 |
|
33 /** |
|
34 * Player for tuner |
|
35 * |
|
36 */ |
|
37 NONSHARABLE_CLASS(CAMMSTunerPlayer) : public CMMAPlayer, |
|
38 public MMMTunerAudioPlayerObserver |
|
39 { |
|
40 public: // Constructors and destructor |
|
41 |
|
42 /** |
|
43 * Two-phased constructor. |
|
44 */ |
|
45 static CAMMSTunerPlayer* NewL(CAMMSTunerControl* aTunerControl); |
|
46 |
|
47 /** |
|
48 * Destructor. |
|
49 */ |
|
50 virtual ~CAMMSTunerPlayer(); |
|
51 |
|
52 public: // from CMMAPlayer |
|
53 |
|
54 void PrefetchL(); |
|
55 void StartL(); |
|
56 void StopL(TBool aPostEvent); |
|
57 void DeallocateL(); |
|
58 void GetMediaTime(TInt64* aMediaTime); |
|
59 |
|
60 public: // from MMMTunerAudioPlayerObserver |
|
61 |
|
62 void MTapoInitializeComplete(TInt aError); |
|
63 void MTapoPlayEvent(MMMTunerAudioPlayerObserver::TEventType aEvent, TInt aError, TAny* aAdditionalInfo); |
|
64 |
|
65 private: |
|
66 |
|
67 /** |
|
68 * C++ default constructor. |
|
69 */ |
|
70 CAMMSTunerPlayer(); |
|
71 |
|
72 /** |
|
73 * By default Symbian 2nd phase constructor is private. |
|
74 */ |
|
75 void ConstructL(CAMMSTunerControl* aTunerControl); |
|
76 |
|
77 |
|
78 TInt64 CurrentTime(); |
|
79 |
|
80 private: // Data |
|
81 CMMTunerAudioPlayerUtility* iTunerPlayerUtility; |
|
82 CAMMSTunerControl* iTunerControl; |
|
83 CActiveSchedulerWait* iActiveSchedulerWait; |
|
84 |
|
85 TBool iIsInitialized; |
|
86 TInt64 iMediaTime; |
|
87 TInt64 iStartTime; |
|
88 }; |
|
89 |
|
90 #endif // CAMMSTUNERPLAYER_H |
|
91 |
|
92 // End of File |