|
1 /* |
|
2 * Copyright (c) 2007-2009 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: ESMR observer for the custom list component |
|
15 * |
|
16 */ |
|
17 |
|
18 #ifndef MESMRLISTOBSERVER_H |
|
19 #define MESMRLISTOBSERVER_H |
|
20 |
|
21 //<cmail> |
|
22 #include "esmrdef.h" |
|
23 //</cmail> |
|
24 |
|
25 class CESMRField; |
|
26 |
|
27 /** |
|
28 * Observer interface for the custom list component. |
|
29 * |
|
30 * @see cesmrlistcomponent.h |
|
31 * @lib esmrgui.lib |
|
32 */ |
|
33 class MESMRListObserver |
|
34 { |
|
35 public: |
|
36 /** |
|
37 * Method to be called when field wants to notify that its size has changed. |
|
38 * By calling this, all the positions and sizes in the list are recalculated |
|
39 * |
|
40 * @param aCtrl - caller field. |
|
41 */ |
|
42 virtual void ControlSizeChanged( CESMRField* aCtrl ) = 0; |
|
43 |
|
44 /** |
|
45 * Sets field to be visible in the list. |
|
46 * |
|
47 * @param aField - id of the field. |
|
48 */ |
|
49 virtual void InsertControl( TESMREntryFieldId aField ) = 0; |
|
50 |
|
51 /** |
|
52 * Disables field in the list. This method does not delete field. |
|
53 * |
|
54 * @param aField - id of the field. |
|
55 */ |
|
56 virtual void RemoveControl( TESMREntryFieldId aField ) = 0; |
|
57 |
|
58 /** |
|
59 * Is field visible or not. |
|
60 * |
|
61 * @return Boolean ETrue/EFalse |
|
62 */ |
|
63 virtual TBool IsControlVisible( TESMREntryFieldId aField ) = 0; |
|
64 |
|
65 /** |
|
66 * Sets field to be focused. |
|
67 * |
|
68 * @param aField - id of the field. |
|
69 */ |
|
70 virtual void SetControlFocusedL( TESMREntryFieldId aField ) = 0; |
|
71 |
|
72 /** |
|
73 * Scrolls the specific field to be fully visible |
|
74 * |
|
75 * @param aInd Index of the field that needs to be fully visible |
|
76 * @param aSizeChanged ETrue if the field size has been changed |
|
77 */ |
|
78 virtual void ScrollItemVisible( TInt aInd ) = 0; |
|
79 |
|
80 // SCROLLING_MOD: Two methods for CESMRRichTextViewer usage |
|
81 virtual void MoveListAreaDownL( TInt aAmount) = 0; |
|
82 virtual void MoveListAreaUpL(TInt aAmount) = 0; |
|
83 |
|
84 virtual TInt ListHeight() = 0; |
|
85 virtual TBool IsFieldBottomVisible() = 0; |
|
86 }; |
|
87 |
|
88 #endif // MESMRLISTOBSERVER_H |