|
1 /* |
|
2 * Copyright (c) 2009 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 #ifndef MRADIOCONTROLEVENTOBSERVER_H |
|
19 #define MRADIOCONTROLEVENTOBSERVER_H |
|
20 |
|
21 // System includes |
|
22 #include <e32std.h> |
|
23 |
|
24 // User includes |
|
25 #include "radioenginedef.h" |
|
26 |
|
27 /** |
|
28 * MRadioControlEventObserver |
|
29 * |
|
30 * MRadioControlEventObserver defines observer interface for radio engine control events. |
|
31 */ |
|
32 NONSHARABLE_CLASS( MRadioControlEventObserver ) |
|
33 { |
|
34 public: |
|
35 |
|
36 /** |
|
37 * Called when "step to channel" request occurs. |
|
38 * |
|
39 * @param aDirection If ERadioUp steps up, otherwise steps down |
|
40 */ |
|
41 virtual void StepToChannelL( RadioEngine::TRadioTuneDirection aDirection ) = 0; |
|
42 |
|
43 /** |
|
44 * Called when "set channel" request occurs. |
|
45 * |
|
46 * @param aChannelId Channel id to set |
|
47 */ |
|
48 virtual void SetChannelL( TInt aChannelId ) = 0; |
|
49 |
|
50 /** |
|
51 * Called when "seek" request occurs. |
|
52 * |
|
53 * @param aDirection If ERadioUp seeks up, otherwise seeks down |
|
54 */ |
|
55 virtual void SeekL( RadioEngine::TRadioTuneDirection aDirection ) = 0; |
|
56 |
|
57 /** |
|
58 * Called when "step to frequency up" request occurs. |
|
59 * |
|
60 * @param aDirection If ERadioUp steps up, otherwise steps down |
|
61 */ |
|
62 virtual void StepToFrequencyL( RadioEngine::TRadioTuneDirection aDirection ) = 0; |
|
63 |
|
64 /** |
|
65 * Called when "set frequency" request occurs. |
|
66 * |
|
67 * @param aFreq Frequency to set |
|
68 */ |
|
69 virtual void SetFrequencyL( TUint32 aFreq ) = 0; |
|
70 |
|
71 /** |
|
72 * Called when "adjust volume" request occurs. |
|
73 * |
|
74 * @param aDirection If ERadioDecVolume decreases, otherwise increases |
|
75 * volume |
|
76 */ |
|
77 virtual void AdjustVolumeL( RadioEngine::TRadioVolumeSetDirection aDirection ) = 0; |
|
78 |
|
79 /** |
|
80 * Called when "mute" request occurs. |
|
81 * |
|
82 * @param aMute if ETrue mutes, else unmutes radio |
|
83 */ |
|
84 virtual void MuteL( TBool aMute ) = 0; |
|
85 |
|
86 /** |
|
87 * Called when "play" request occurs. |
|
88 * |
|
89 * @param aDownPressed If ETrue, button is down. If EFalse, button is up. |
|
90 */ |
|
91 virtual void PlayL( TBool aDownPressed ) = 0; |
|
92 |
|
93 /** |
|
94 * Called when "pause" request occurs. |
|
95 * |
|
96 * @param aDownPressed If ETrue, button is down. If EFalse, button is up. |
|
97 */ |
|
98 virtual void PauseL( TBool aDownPressed ) = 0; |
|
99 |
|
100 /** |
|
101 * Called when "play", "pause" or "pauseplay" request occurs. |
|
102 * |
|
103 * @param aDownPressed If ETrue, button is down. If EFalse, button is up. |
|
104 */ |
|
105 virtual void PausePlayL( TBool aDownPressed ) = 0; |
|
106 |
|
107 /** |
|
108 * Called when "stop" request occurs. |
|
109 * |
|
110 * @param aDownPressed If ETrue, button is down. If EFalse, button is up. |
|
111 */ |
|
112 virtual void StopL( TBool aDownPressed ) = 0; |
|
113 |
|
114 /** |
|
115 * Called when "forward" request occurs. |
|
116 * |
|
117 * @param aDownPressed If ETrue, button is down. If EFalse, button is up. |
|
118 */ |
|
119 virtual void ForwardL( TBool aDownPressed ) = 0; |
|
120 |
|
121 /** |
|
122 * Called when "fast forward" request occurs. |
|
123 * |
|
124 * @param aDownPressed If ETrue, button is down. If EFalse, button is up. |
|
125 */ |
|
126 virtual void FastForwardL( TBool aDownPressed ) = 0; |
|
127 |
|
128 /** |
|
129 * Called when "backward" request occurs. |
|
130 * |
|
131 * @param aDownPressed If ETrue, button is down. If EFalse, button is up. |
|
132 */ |
|
133 virtual void BackwardL( TBool aDownPressed ) = 0; |
|
134 |
|
135 /** |
|
136 * Called when "rewind" request occurs. |
|
137 * |
|
138 * @param aDownPressed If ETrue, button is down. If EFalse, button is up. |
|
139 */ |
|
140 virtual void RewindL( TBool aDownPressed ) = 0; |
|
141 |
|
142 /** |
|
143 * Called when "channel up" request occurs. |
|
144 * |
|
145 * @param aDownPressed If ETrue, button is down. If EFalse, button is up. |
|
146 */ |
|
147 virtual void ChannelUpL( TBool aDownPressed ) = 0; |
|
148 |
|
149 /** |
|
150 * Called when "channel down" request occurs. |
|
151 * |
|
152 * @param aDownPressed If ETrue, button is down. If EFalse, button is up. |
|
153 */ |
|
154 virtual void ChannelDownL( TBool aDownPressed ) = 0; |
|
155 |
|
156 /** |
|
157 * Called when "volume up" request occurs. |
|
158 * |
|
159 * @param aDownPressed If ETrue, button is down. If EFalse, button is up. |
|
160 */ |
|
161 virtual void VolumeUpL( TBool aDownPressed ) = 0; |
|
162 |
|
163 /** |
|
164 * Called when "volume down" request occurs. |
|
165 * |
|
166 * @param aDownPressed If ETrue, button is down. If EFalse, button is up. |
|
167 */ |
|
168 virtual void VolumeDownL( TBool aDownPressed ) = 0; |
|
169 |
|
170 /** |
|
171 * Called when "change view" request occurs |
|
172 * |
|
173 * @param aViewId the id of activated view |
|
174 * @param aForceChange if ETrue, view changing is forced and state |
|
175 * of visual radio is not checked |
|
176 */ |
|
177 virtual void ChangeViewL( TUid aViewId, TBool aForceChange ) = 0; |
|
178 |
|
179 /** |
|
180 * Called when audio route is changed |
|
181 * @param aRoute the current audio route |
|
182 */ |
|
183 virtual void SetAudioRouteL( RadioEngine::TRadioAudioRoute aRoute ) = 0; |
|
184 |
|
185 /** |
|
186 * Called when headset button answer/end call is pressed |
|
187 */ |
|
188 virtual void AnswerEndCallL() = 0; |
|
189 |
|
190 }; |
|
191 |
|
192 #endif // MRADIOCONTROLEVENTOBSERVER_H |