1 /* |
|
2 * Copyright (c) 2002-2005 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: One rows list with icon for drop-down list objects |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef C_CLISTONEROWWITHICON_H |
|
20 #define C_CLISTONEROWWITHICON_H |
|
21 |
|
22 // INCLUDES |
|
23 #include <e32std.h> |
|
24 #include <w32std.h> |
|
25 |
|
26 #include "peninputlist.h" |
|
27 #include "peninputcandidate.h" |
|
28 |
|
29 // class forward decalaration |
|
30 class MFepCtrlDropdownListContext; |
|
31 |
|
32 /** |
|
33 * One rows list without icon for drop-down list |
|
34 * |
|
35 * One rows list without icon for drop-down list |
|
36 * |
|
37 * @lib FepCtrlDropdownList.lib |
|
38 * @since S60 v3.2 |
|
39 */ |
|
40 NONSHARABLE_CLASS(CListOneRowWithIcon) : public CList |
|
41 { |
|
42 |
|
43 public: // Methods |
|
44 |
|
45 /** |
|
46 * Create a object of CListOneRowWithIcon, static method |
|
47 * |
|
48 * @since S60 v3.2 |
|
49 * @param aManager Pointer to the list manager |
|
50 * @param iOwner The drop down list |
|
51 * @return CListOneRowWithIcon pointer. |
|
52 */ |
|
53 static CListOneRowWithIcon* NewL(CListManager* aManager, |
|
54 MFepCtrlDropdownListContext* iOwner); |
|
55 |
|
56 /** |
|
57 * Destructor |
|
58 * |
|
59 * @since S60 v3.2 |
|
60 */ |
|
61 virtual ~CListOneRowWithIcon(); |
|
62 |
|
63 // from base class CList |
|
64 |
|
65 /** |
|
66 * Draw the list |
|
67 * |
|
68 * @since S60 v3.2 |
|
69 */ |
|
70 virtual void Draw(); |
|
71 |
|
72 /** |
|
73 * Update the list, including re-calculate the rect of candidates. |
|
74 * |
|
75 * @since S60 v3.2 |
|
76 * @param aRecalculate Re-calculate or not calculate the rect of candidates, the default is re-calculate |
|
77 */ |
|
78 virtual void UpdateListL(TBool aDrawFlag = ETrue, TBool aRecalculate = ETrue); |
|
79 |
|
80 /** |
|
81 * Deal with the pointer down event. |
|
82 * |
|
83 * @since S60 v3.2 |
|
84 * @param aPoint The point of the mouse |
|
85 * @return None. |
|
86 */ |
|
87 virtual void HandlePointerDownL(const TPoint& aPoint); |
|
88 |
|
89 /** |
|
90 * Deal with the pointer up event. |
|
91 * |
|
92 * @since S60 v3.2 |
|
93 * @param aPoint The point of the mouse |
|
94 * @return None. |
|
95 */ |
|
96 virtual void HandlePointerUpL(const TPoint& aPoint); |
|
97 |
|
98 /** |
|
99 * Deal with the pointer drag event. |
|
100 * |
|
101 * @since S60 v3.2 |
|
102 * @param aPoint The point of the mouse |
|
103 * @return None. |
|
104 */ |
|
105 virtual void HandlePointerDragL(const TPoint& aPoint); |
|
106 |
|
107 protected: // Methods |
|
108 |
|
109 /** |
|
110 * Constructor. |
|
111 * |
|
112 * @param aManager The list manager |
|
113 * @param aOwner The context of the drop down list |
|
114 * @since S60 v3.2 |
|
115 */ |
|
116 CListOneRowWithIcon(CListManager* aManager, MFepCtrlDropdownListContext* aOwner); |
|
117 |
|
118 // from base class CList |
|
119 |
|
120 /** |
|
121 * Draw navigation button when pressed. |
|
122 * |
|
123 * @since S60 v3.2 |
|
124 * @param aRect The rect which will be drawn |
|
125 * @param aIndicate Indicate the button is pressed or not |
|
126 */ |
|
127 TBool DrawNavigationPress(const TRect& aRect, TBool aIndicate); |
|
128 |
|
129 protected: |
|
130 |
|
131 /** |
|
132 * Calculate the position of current visible candidates. |
|
133 * |
|
134 * @since S60 v3.2 |
|
135 * @return the last candidate visible. |
|
136 */ |
|
137 virtual TInt CalculatePositionsL(); |
|
138 |
|
139 /** |
|
140 * Calculate all kinds of rectangles of list. |
|
141 * |
|
142 * @since S60 v3.2 |
|
143 */ |
|
144 virtual void CalculateAreas(); |
|
145 |
|
146 protected: |
|
147 |
|
148 /** |
|
149 * the bitmap for next button |
|
150 * Not own |
|
151 */ |
|
152 const CFbsBitmap* iBButtonDown; |
|
153 |
|
154 /** |
|
155 * the mask bitmap for next button |
|
156 * Not own |
|
157 */ |
|
158 const CFbsBitmap* iBButtonMaskDown; |
|
159 |
|
160 }; |
|
161 |
|
162 #endif //C_CLISTONEROWWITHICON_H |
|
163 |
|
164 // End Of File |
|