|
1 /* |
|
2 * Copyright (c) 2005-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: Phonebook 2 contact editor UI extension interface. |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef MPBK2CONTACTEDITOREXTENSION_H |
|
20 #define MPBK2CONTACTEDITOREXTENSION_H |
|
21 |
|
22 // INCLUDES |
|
23 #include <MPbk2UiReleasable.h> |
|
24 #include <MPbk2ContactEditorEventObserver.h> |
|
25 |
|
26 // FORWARD DECLARATIONS |
|
27 class MVPbkStoreContactField; |
|
28 class MPbk2ContactEditorField; |
|
29 class MPbk2ContactEditorUiBuilder; |
|
30 class CEikMenuPane; |
|
31 class MPbk2FieldProperty; |
|
32 class CEikButtonGroupContainer; |
|
33 class CPbk2IconInfoContainer; |
|
34 |
|
35 // CLASS DECLARATION |
|
36 |
|
37 /** |
|
38 * Phonebook 2 contact editor UI extension interface. |
|
39 */ |
|
40 class MPbk2ContactEditorExtension : public MPbk2UiReleasable, |
|
41 public MPbk2ContactEditorEventObserver |
|
42 { |
|
43 public: // Interface |
|
44 |
|
45 /** |
|
46 * Creates a new contact editor field. |
|
47 * |
|
48 * @param aField The field to create editor field for. |
|
49 * @param aFieldProperty Field property. |
|
50 * @param aUiBuilder Builder for adding the field into dialog. |
|
51 * @param aIconInfoContainer Icon container for setting the icon. |
|
52 * @return A new contact editor field or NULL. |
|
53 */ |
|
54 virtual MPbk2ContactEditorField* CreateEditorFieldL( |
|
55 MVPbkStoreContactField& aContactField, |
|
56 const MPbk2FieldProperty& aFieldProperty, |
|
57 MPbk2ContactEditorUiBuilder& aUiBuilder, |
|
58 CPbk2IconInfoContainer& aIconInfoContainer ) = 0; |
|
59 |
|
60 /** |
|
61 * Filters the menu pane of the Phonebook 2 contact editor. |
|
62 * |
|
63 * @param aResourceId Menu resource id. |
|
64 * @param aMenuPane Menu pane which will be filtered. |
|
65 */ |
|
66 virtual void DynInitMenuPaneL( |
|
67 TInt aResourceId, |
|
68 CEikMenuPane* aMenuPane ) = 0; |
|
69 |
|
70 /** |
|
71 * Processes extension commands. |
|
72 * |
|
73 * @param aCommandId Command id. |
|
74 * @return ETrue if command was handled, EFalse otherwise. |
|
75 */ |
|
76 virtual TBool ProcessCommandL( |
|
77 TInt aCommandId ) = 0; |
|
78 |
|
79 /** |
|
80 * For adding additional functionality before deleting |
|
81 * the contact and exiting editor. |
|
82 * |
|
83 * @param aParams Event parameters. |
|
84 * @return ETrue if the delete and exit is ok, EFalse otherwise. |
|
85 */ |
|
86 virtual TBool OkToDeleteContactL( |
|
87 MPbk2ContactEditorEventObserver::TParams& aParams ) = 0; |
|
88 |
|
89 /** |
|
90 * For adding additional functionality before saving |
|
91 * the contact and exiting editor. |
|
92 * |
|
93 * @param aParams Event parameters. |
|
94 * @return ETrue if the save and exit is ok, EFalse otherwise. |
|
95 */ |
|
96 virtual TBool OkToSaveContactL( |
|
97 MPbk2ContactEditorEventObserver::TParams& aParams ) = 0; |
|
98 |
|
99 /** |
|
100 * For modifying a dialog's button group. Called before dialog |
|
101 * have been activated. |
|
102 * |
|
103 * @param aButtonGroupContainer Dialog's button group container. |
|
104 */ |
|
105 virtual void ModifyButtonGroupContainerL( |
|
106 CEikButtonGroupContainer& aButtonGroupContainer ) = 0; |
|
107 |
|
108 /** |
|
109 * Returns an extension point for this interface or NULL. |
|
110 * |
|
111 * @param aExtensionUid Extension UID. |
|
112 * @return Extension point. |
|
113 */ |
|
114 virtual TAny* ContactEditorExtensionExtension( |
|
115 TUid /*aExtensionUid*/ ) |
|
116 { |
|
117 return NULL; |
|
118 } |
|
119 }; |
|
120 |
|
121 #endif // MPBK2CONTACTEDITOREXTENSION_H |
|
122 |
|
123 // End of File |