1 /* |
|
2 * Copyright (c) 2007 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: Definition of the class CPbkxRclQueryEditor. |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef CPBKXRCLQUERYEDITOR_H |
|
20 #define CPBKXRCLQUERYEDITOR_H |
|
21 |
|
22 #include <AknQueryDialog.h> |
|
23 |
|
24 /** |
|
25 * Provides an UI that lets user to edit the search query. |
|
26 * |
|
27 * @lib pbkxrclengine.lib |
|
28 * @since S60 3.1 |
|
29 */ |
|
30 class CPbkxRclQueryEditor : public CAknTextQueryDialog |
|
31 { |
|
32 public: // constructor and destructor |
|
33 |
|
34 /** |
|
35 * Two-phased constructor. |
|
36 * |
|
37 * @param aAccountName name of the remote lookup account |
|
38 * @param aQueryText query text |
|
39 * @return Created object. |
|
40 */ |
|
41 static CPbkxRclQueryEditor* NewL( |
|
42 const TDesC& aAccountName, |
|
43 TDes& aQueryText ); |
|
44 |
|
45 /** |
|
46 * Destructor. |
|
47 */ |
|
48 virtual ~CPbkxRclQueryEditor(); |
|
49 |
|
50 public: // new methods |
|
51 |
|
52 /** |
|
53 * Execute UI that lets the user edit the query and returns the edited |
|
54 * query back to the user. |
|
55 * |
|
56 * @return ETrue if user selected Ok, EFalse otherwise. |
|
57 */ |
|
58 TBool ExecuteDialogLD(); |
|
59 |
|
60 private: // methods used internally |
|
61 |
|
62 /** |
|
63 * Sets editor input mode based on user input. |
|
64 * |
|
65 * If there is at least one alpha character then text input mode is |
|
66 * selected. Otherwise input mode is numerical. |
|
67 */ |
|
68 void SetEditorInputModeL(); |
|
69 |
|
70 private: // constructors |
|
71 |
|
72 /** |
|
73 * Constructor. |
|
74 * |
|
75 * @param aQueryText Handle to query text. |
|
76 */ |
|
77 CPbkxRclQueryEditor( TDes& aQueryText ); |
|
78 |
|
79 /** |
|
80 * Second-phase constructor. |
|
81 * |
|
82 * @param aAccountName Account name used to create prompt text. |
|
83 */ |
|
84 void ConstructL( const TDesC& aAccountName ); |
|
85 |
|
86 }; |
|
87 |
|
88 #endif // CPBKXRCLQUERYEDITOR_H |
|
89 |
|