|
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: |
|
15 * Phonebook call number selection dialog. This dialog implements the call |
|
16 * number selection logic of Phonebook. |
|
17 * |
|
18 */ |
|
19 |
|
20 |
|
21 #ifndef __CPbkSendKeyAddressSelect_H__ |
|
22 #define __CPbkSendKeyAddressSelect_H__ |
|
23 |
|
24 // INCLUDES |
|
25 #include "CPbkAddressSelect.h" |
|
26 |
|
27 // FORWARD DECLARATIONS |
|
28 class CPbkContactEngine; |
|
29 |
|
30 // CLASS DECLARATION |
|
31 |
|
32 /** |
|
33 * Phonebook call number selection dialog. This dialog implements the call |
|
34 * number selection logic of Phonebook. |
|
35 */ |
|
36 class CPbkSendKeyAddressSelect : public CPbkAddressSelect |
|
37 { |
|
38 public: // Interface |
|
39 /** |
|
40 * Constructor. |
|
41 * @param aContactEngine Phonebook contact engine. |
|
42 */ |
|
43 IMPORT_C CPbkSendKeyAddressSelect( |
|
44 CPbkContactEngine& aContactEngine); |
|
45 |
|
46 /** |
|
47 * Parameters for ExecuteLD(TParams&). |
|
48 * |
|
49 * @see CPbkAddressSelect::TBaseParams |
|
50 * @see ExecuteLD(TParams&) |
|
51 */ |
|
52 class TParams : public CPbkAddressSelect::TBaseParams |
|
53 { |
|
54 public: |
|
55 /** |
|
56 * Constructor. |
|
57 * @param aContactItem contact where to select a phone number. |
|
58 * @param aDefaultField default field to use |
|
59 */ |
|
60 IMPORT_C TParams(const CPbkContactItem& aContact, |
|
61 const TPbkContactItemField* aDefaultField); |
|
62 |
|
63 private: // data |
|
64 /// Own: spare data |
|
65 TInt32 iSpare1; |
|
66 }; |
|
67 |
|
68 /** |
|
69 * Runs the phone number selection query (if necessary). |
|
70 * |
|
71 * @param aParams parameters and return values object of the query. |
|
72 * @return true if query was accepted, false if canceled. |
|
73 * @see TParams |
|
74 */ |
|
75 IMPORT_C TBool ExecuteLD(TParams& aParams); |
|
76 |
|
77 /** |
|
78 * Destructor. |
|
79 */ |
|
80 IMPORT_C ~CPbkSendKeyAddressSelect(); |
|
81 |
|
82 private: // from CPbkAddressSelect |
|
83 IMPORT_C const TDesC& QueryTitleL(); |
|
84 IMPORT_C TInt QuerySoftkeysResource() const; |
|
85 IMPORT_C TKeyResponse PbkControlKeyEventL |
|
86 (const TKeyEvent& aKeyEvent,TEventCode aType); |
|
87 IMPORT_C TBool AddressField(const TPbkContactItemField& aField) const; |
|
88 IMPORT_C void NoAddressesL(); |
|
89 |
|
90 private: // data members |
|
91 /// Own: Title for phonenumber selection list |
|
92 HBufC* iQueryTitle; |
|
93 /// Ref: Phonebook engine |
|
94 CPbkContactEngine& iEngine; |
|
95 // Spare data |
|
96 TInt32 iSpare1; |
|
97 }; |
|
98 |
|
99 #endif // __CPbkSendKeyAddressSelect_H__ |
|
100 |
|
101 // End of File |