|
1 /* |
|
2 * Copyright (c) 2005-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 |
|
19 |
|
20 #ifndef T_CTELEPHONYAUDIOROUTINGDATA_H_ |
|
21 #define T_CTELEPHONYAUDIOROUTINGDATA_H_ |
|
22 |
|
23 //User includes |
|
24 #include "datawrapperbase.h" |
|
25 |
|
26 //Epoc includes |
|
27 #include <mtelephonyaudioroutingobserver.h>//MTelephonyAudioRoutingObserver |
|
28 #include <telephonyaudiorouting.h>//CTelephonyAudioRouting |
|
29 /** |
|
30 * This class tests the CTelephonyAudioRouting API's |
|
31 */ |
|
32 |
|
33 class CT_CTelephonyAudioRoutingData : public CDataWrapperBase, public MTelephonyAudioRoutingObserver |
|
34 { |
|
35 public: |
|
36 ~CT_CTelephonyAudioRoutingData(); |
|
37 static CT_CTelephonyAudioRoutingData* NewL(); |
|
38 virtual TAny* GetObject(); |
|
39 virtual TBool DoCommandL(const TTEFFunction& aCommand, const TTEFSectionName& aSection, const TInt aAsyncErrorIndex); |
|
40 |
|
41 private: |
|
42 CT_CTelephonyAudioRoutingData(); |
|
43 // void ConstructL(); |
|
44 void DestroyData(); |
|
45 |
|
46 public: |
|
47 /** |
|
48 * From MAudioOutputObserver |
|
49 */ |
|
50 void AvailableOutputsChanged( CTelephonyAudioRouting& /*aTelephonyAudioRouting*/); |
|
51 void OutputChanged( CTelephonyAudioRouting& /*aTelephonyAudioRouting*/); |
|
52 void SetOutputComplete( CTelephonyAudioRouting& /*aTelephonyAudioRouting*/, TInt aError); |
|
53 |
|
54 protected: |
|
55 void DoCmdNewL(); |
|
56 void DoCmdDestructor(); |
|
57 void DoCmdAvailableOutputs(); |
|
58 void DoCmdOutput(); |
|
59 void DoCmdPreviousOutput(); |
|
60 void DoCmdSetShowNote(const TTEFSectionName& aSection); |
|
61 void DoCmdGetShowNote(); |
|
62 void DoCmdSetOutputL(const TTEFSectionName& aSection); |
|
63 |
|
64 private: |
|
65 /** |
|
66 * Wrapped object |
|
67 */ |
|
68 CTelephonyAudioRouting* iTelephonyAudioRouting; |
|
69 /** |
|
70 * Current output configured |
|
71 */ |
|
72 CTelephonyAudioRouting::TAudioOutput iOutput; |
|
73 /** |
|
74 * Enum for output routing |
|
75 */ |
|
76 static const TEnumEntryTable iEnumOutput[]; |
|
77 }; |
|
78 |
|
79 #endif /*T_CTELEPHONYAUDIOROUTING_H_*/ |