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: CAudioEqualizerUtility stub for testing mpmpxframeworkwrapper |
|
15 * |
|
16 */ |
|
17 |
|
18 #ifndef CAUDIOEQUALIZERUTILITY_H |
|
19 #define CAUDIOEQUALIZERUTILITY_H |
|
20 |
|
21 // INCLUDES |
|
22 #include <e32base.h> |
|
23 #include <e32svr.h> |
|
24 #include <AudioEqualizerBase.h> |
|
25 #include <centralrepository.h> |
|
26 #include <AudioEqualizerUtilityData.h> |
|
27 |
|
28 // FORWARD DECLARATIONS |
|
29 class CMdaAudioPlayerUtility; |
|
30 class CRepository; |
|
31 |
|
32 |
|
33 // CLASS DECLARATION |
|
34 |
|
35 /** |
|
36 * This is the Equalizer Utility class for managing audio equalizer presets. |
|
37 * |
|
38 * @lib AudioEqualizerUtility.lib |
|
39 * @since 3.0 |
|
40 */ |
|
41 |
|
42 class CAudioEqualizerUtility : public CBase |
|
43 { |
|
44 public: // Constructors and destructor |
|
45 |
|
46 /** |
|
47 * Factory function for creating the audio equalizer utility object. |
|
48 * @since 3.0 |
|
49 * @param aUtility A reference to a audio player utility |
|
50 * @return pointer to CAudioEqualizerUtility object |
|
51 */ |
|
52 static CAudioEqualizerUtility* NewL(CMdaAudioPlayerUtility& aUtility); |
|
53 |
|
54 /** |
|
55 * Destructor. |
|
56 */ |
|
57 virtual ~CAudioEqualizerUtility(); |
|
58 |
|
59 /** |
|
60 * Apply the Preset Index value |
|
61 * @since 3.0 |
|
62 * @param aPreset Preset Value |
|
63 */ |
|
64 void ApplyPresetL(TInt aPreset); |
|
65 |
|
66 /** |
|
67 * Disable the Equalizer |
|
68 * @since 3.0 |
|
69 */ |
|
70 void DisableEqualizerL(); |
|
71 |
|
72 /** |
|
73 * Retrieves a Preset with the given index from the Central Repository |
|
74 * @since 3.0 |
|
75 * @param aPresetIndex Index of the Preset in the Array |
|
76 */ |
|
77 const TDesC& GetPresetL(TInt aPresetIndex); |
|
78 |
|
79 /** |
|
80 * Get all the Presets defined in the Central Repository |
|
81 * @since 3.0 |
|
82 * @return Array of all Presets. |
|
83 */ |
|
84 TArray<TEfAudioEqualizerUtilityPreset> Presets(); |
|
85 |
|
86 private: |
|
87 |
|
88 /** |
|
89 * C++ default constructor. |
|
90 */ |
|
91 CAudioEqualizerUtility(); |
|
92 |
|
93 /** |
|
94 * By default Symbian 2nd phase constructor is private. |
|
95 */ |
|
96 |
|
97 /** |
|
98 * Second Phase Costructor for CMdaAudioPlayerUtility |
|
99 * @since 3.0 |
|
100 * @param aUtility CMdaAudioPlayerUtility Referece |
|
101 */ |
|
102 void ConstructL(CMdaAudioPlayerUtility& aUtility); |
|
103 |
|
104 |
|
105 /** |
|
106 * Function of Updating the Preset Array for the User |
|
107 * @since 3.0 |
|
108 * @param aUtility MCustomInterface Referece |
|
109 */ |
|
110 void UpdatePresetArray(RArray<TEfAudioEqualizerUtilityPreset>& aPresetArray); |
|
111 |
|
112 private: // Data |
|
113 |
|
114 // Array for Storing the Current State of the Repository |
|
115 // which has been compacted after the transaction |
|
116 // with the Central Repository |
|
117 RArray<TEfAudioEqualizerUtilityPreset> iPresetArray; |
|
118 |
|
119 }; |
|
120 |
|
121 #endif // CAUDIOEQUALIZERUTILITY_H |
|
122 // End of File |
|