|
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: CenRep handling for DevTts |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef DEVTTSCENREP_H |
|
20 #define DEVTTSCENREP_H |
|
21 |
|
22 // INCLUDES |
|
23 #include <e32base.h> |
|
24 #include <nssdevtts.h> |
|
25 #include <centralrepository.h> |
|
26 |
|
27 // CLASS DECLARATION |
|
28 |
|
29 /** |
|
30 * Playback volume CenRep handler for DevTTS |
|
31 */ |
|
32 NONSHARABLE_CLASS( CDevTtsCenRep ) : public CBase |
|
33 { |
|
34 public: // Constructors and destructor |
|
35 |
|
36 /** |
|
37 * Two-phased constructor. |
|
38 */ |
|
39 static CDevTtsCenRep* NewL(); |
|
40 |
|
41 /** |
|
42 * Destructor. |
|
43 */ |
|
44 virtual ~CDevTtsCenRep(); |
|
45 |
|
46 public: // New functions |
|
47 |
|
48 /** |
|
49 * Returns the current volume setting from CenRep. |
|
50 * If nothing is found (or error occurs), maximum volume will be returned. |
|
51 * Volume setting is scaled to 0..aMaxVolume |
|
52 * |
|
53 * @param "TInt aMaxVolume" Maximum volume |
|
54 * @return Volume setting read from CenRep |
|
55 */ |
|
56 TInt Volume( TInt aMaxVolume ); |
|
57 |
|
58 public: // Functions from base classes |
|
59 |
|
60 private: |
|
61 |
|
62 /** |
|
63 * C++ default constructor. |
|
64 */ |
|
65 CDevTtsCenRep(); |
|
66 |
|
67 /** |
|
68 * By default Symbian 2nd phase constructor is private. |
|
69 */ |
|
70 void ConstructL(); |
|
71 |
|
72 // Prohibit copy constructor |
|
73 CDevTtsCenRep( const CDevTtsCenRep& ); |
|
74 // Prohibit assigment operator |
|
75 CDevTtsCenRep& operator=( const CDevTtsCenRep& ); |
|
76 |
|
77 private: // Data |
|
78 |
|
79 // Central Repository |
|
80 CRepository* iRepository; |
|
81 |
|
82 }; |
|
83 |
|
84 #endif // DEVTTSCENREP_H |
|
85 |
|
86 // End of File |