|
1 /* |
|
2 * Copyright (c) 2007-2008 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: Extension handler class. |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef C_CPHONEEXTENSIONHANDLER_H |
|
20 #define C_CPHONEEXTENSIONHANDLER_H |
|
21 |
|
22 // INCLUDES |
|
23 #include <telmenuextension.h> |
|
24 #include <spdefinitions.h> |
|
25 #include "mphonebuttoncustomization.h" |
|
26 |
|
27 // FORWARD DECLARATIONS |
|
28 class CPhMenuExtensionWrapper; |
|
29 |
|
30 // CLASS DECLARATION |
|
31 /** |
|
32 * Extension handler class |
|
33 */ |
|
34 NONSHARABLE_CLASS( CPhoneExtensionHandler ): public CBase |
|
35 { |
|
36 |
|
37 public: |
|
38 |
|
39 /** |
|
40 * Destructor. |
|
41 */ |
|
42 virtual ~CPhoneExtensionHandler(); |
|
43 |
|
44 /** |
|
45 * Creates the extension handler class |
|
46 */ |
|
47 static CPhoneExtensionHandler* NewL(); |
|
48 |
|
49 /** |
|
50 * Customizes touch pane buttons. |
|
51 * @param aServiceId Service id of the call. |
|
52 * @param aArray Active call array |
|
53 * @param aTouchPane Interface to add and dimm |
|
54 * bubble touch pane buttons. |
|
55 */ |
|
56 void CustomizeTouchPaneButtonsL( |
|
57 TUint aServiceId, |
|
58 RArray<CTelMenuExtension::TCallInfo>& aArray, |
|
59 MBubbleTouchPaneInterface& aTouchPane ); |
|
60 |
|
61 /** |
|
62 * Modifies menu when there is active call. |
|
63 * @param aServiceId Service id of the call. |
|
64 * @param aArray Active call array |
|
65 * @param aResourceId Menu resource id. |
|
66 * @param aMenuPane Menu pane |
|
67 */ |
|
68 void ModifyInCallMenuL( |
|
69 TUint aServiceId, |
|
70 RArray<CTelMenuExtension::TCallInfo>& aArray, |
|
71 TInt aResourceId, |
|
72 CEikMenuPane& aMenuPane ); |
|
73 |
|
74 /** |
|
75 * Handles custom menu command. |
|
76 * @param aServiceId Service id of the call. |
|
77 * @param aCommand Command id. |
|
78 * @return ETrue if command handled. |
|
79 */ |
|
80 TBool HandleCommandL( |
|
81 TUint aServiceId, |
|
82 TInt aCommand ); |
|
83 |
|
84 protected: |
|
85 |
|
86 CPhoneExtensionHandler(); |
|
87 |
|
88 void ConstructL(); |
|
89 |
|
90 private: |
|
91 |
|
92 |
|
93 /** |
|
94 * Resolves extensions implementation uid for |
|
95 * given service id. |
|
96 * @leave KErrNotFound if extension not exists for service. |
|
97 * @param aServiceId Service id |
|
98 * @param aPropertyName Service table property name. |
|
99 * @return Implementaion uid. |
|
100 */ |
|
101 TUid ResolveImplementationUidL( TUint32 aServiceId, |
|
102 TServicePropertyName aPropertyName ); |
|
103 |
|
104 /** |
|
105 * Adds unattended transfer menu item to menu. |
|
106 * @param aMenuPane Menu pane. |
|
107 */ |
|
108 void AddUnattendedTransferMenuItemL( CEikMenuPane& aMenuPane ); |
|
109 |
|
110 /** |
|
111 * Returns menu extension by service id. |
|
112 * @leave Leaves if not found. |
|
113 * @param aServiceId Service id of call |
|
114 */ |
|
115 CTelMenuExtension* MenuExtensionL( TUint aServiceId ); |
|
116 |
|
117 |
|
118 private: // Data |
|
119 |
|
120 |
|
121 /** |
|
122 * Menu extension plugins. |
|
123 * Own. |
|
124 */ |
|
125 RPointerArray<CPhMenuExtensionWrapper> iPlugins; |
|
126 }; |
|
127 |
|
128 #endif // C_CPHONEVOIPUTILITY_H |
|
129 |
|
130 // End of File |