|
1 /* |
|
2 * Copyright (c) 2002 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: It defines interface for speed dial for phone app. |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef CPHCNTSPEEDDIALMONITOR_H |
|
20 #define CPHCNTSPEEDDIALMONITOR_H |
|
21 |
|
22 // INCLUDES |
|
23 #include <e32base.h> |
|
24 #include <mphcntmatch.h> |
|
25 |
|
26 // CONSTANTS |
|
27 const TInt KPhCntContactItemNotFound = -1; |
|
28 const TInt KPhCntInvalidIndex = -1; |
|
29 |
|
30 // CLASS DECLARATION |
|
31 class CSpdiaControl; |
|
32 class CEikImage; |
|
33 class MVPbkContactLink; |
|
34 class CPhCntContactId; |
|
35 |
|
36 /** |
|
37 * It defines interface for speed dial for phone app. |
|
38 * |
|
39 * @lib PhoneCntFinder |
|
40 * @since 1.0 |
|
41 */ |
|
42 NONSHARABLE_CLASS( CPhCntSpeedDialMonitor ) |
|
43 : public CBase |
|
44 { |
|
45 public: // New functions |
|
46 |
|
47 /** |
|
48 * Structure holding speed dial information. |
|
49 */ |
|
50 struct TSpdDialFieldInfo |
|
51 { |
|
52 MPhCntMatch::TNumberType iNumberType; |
|
53 }; |
|
54 |
|
55 /** |
|
56 * Gets the speed dial number. |
|
57 * |
|
58 * @param aSpeedDialPosition a speed dial position |
|
59 * @return aPhoneNumber phone number |
|
60 * @return error code, KErrNone if success |
|
61 */ |
|
62 virtual TInt GetSpeedDialFieldL( |
|
63 TInt aSpeedDialPosition, |
|
64 TDes& aPhoneNumber ) = 0; |
|
65 |
|
66 /** |
|
67 * Gets the speed dial number. |
|
68 * |
|
69 * @param aSpeedDialPosition a speed dial position |
|
70 * @return aPhoneNumber phone number |
|
71 * @return aFieldInfo speed dial contact information |
|
72 * @return error code, KErrNone if success |
|
73 */ |
|
74 virtual TInt GetSpeedDialFieldL( |
|
75 TInt aSpeedDialPosition, |
|
76 TDes& aPhoneNumber, |
|
77 TSpdDialFieldInfo& aFieldInfo ) = 0; |
|
78 |
|
79 /** |
|
80 * Assigns phone number to speed dial location |
|
81 * |
|
82 * @param aSpeedDialPosition the speed dial position |
|
83 * @return aPhoneNumber If the number is assigned successfully, phone |
|
84 * return the phone number |
|
85 * @return KErrNone if successfully assigned, KErrNotFound if user |
|
86 * cancel the assignation |
|
87 */ |
|
88 virtual TInt AssignSpeedDialFieldL( |
|
89 TInt aSpeedDialPosition, |
|
90 TDes& aPhoneNumber ) = 0; |
|
91 |
|
92 /** |
|
93 * Assigns phone number to speed dial location |
|
94 * |
|
95 * @param aSpeedDialPosition the speed dial position |
|
96 * @return aPhoneNumber If the number is assigned successfully, phone |
|
97 * return the phone number |
|
98 * @return aFieldInfo speed dial contact information |
|
99 * @return KErrNone if successfully assigned, KErrNotFound if user |
|
100 * cancel the assignation |
|
101 */ |
|
102 virtual TInt AssignSpeedDialFieldL( |
|
103 TInt aSpeedDialPosition, |
|
104 TDes& aPhoneNumber, |
|
105 TSpdDialFieldInfo& aFieldInfo ) = 0; |
|
106 |
|
107 /** |
|
108 * Cancel speed dialing assignment process |
|
109 */ |
|
110 virtual void Cancel() = 0; |
|
111 |
|
112 /** |
|
113 * Create number type icon from phone book view |
|
114 * @param aNumberType the number type |
|
115 * @return returns a object of CEikImage |
|
116 */ |
|
117 virtual CEikImage* CreateNumberTypeIconLC( TInt aNumberType ) = 0; |
|
118 |
|
119 }; |
|
120 |
|
121 #endif // CPHCNTSPEEDDIALMONITOR_H |
|
122 |
|
123 // End of File |