|
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: header file of base controls |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef C_CFEPUIBASECTRL_H |
|
20 #define C_CFEPUIBASECTRL_H |
|
21 |
|
22 #include <e32base.h> |
|
23 #include <w32std.h> |
|
24 #include <w32adll.h> |
|
25 #include <peninputuilayoutownerinf.h> |
|
26 #include <peninputuilayoutbase.h> |
|
27 #include <peninputlayoutminterface.h> |
|
28 |
|
29 class CFepUiLayout; |
|
30 class CLayoutTimer; |
|
31 class CCandidateWnd; |
|
32 class CFepUiLayoutRootCtrl; |
|
33 class CCoeControl; |
|
34 |
|
35 const TInt KDefaultFrameWidth = 1; |
|
36 // There are 8 shadow bitmaps |
|
37 const TInt KShadowBitmapTotalNum = 8; |
|
38 //for mask bitmap |
|
39 const TUint32 KTransparentColor = 0x0; |
|
40 const TUint32 KOpaqueColor = 0xffffff; |
|
41 |
|
42 #define KDEFAULTBASELINERATIO 3/4 |
|
43 //base control type |
|
44 typedef TInt64 TControlType; |
|
45 |
|
46 //UI layout leave code |
|
47 enum TUiLayoutErrorCode |
|
48 { |
|
49 EUiLayoutNotReady = -2000, |
|
50 EUiLayoutOwnerNotReady, |
|
51 EUiLayoutBadControlIndex, |
|
52 EUiLayoutBadEvent, |
|
53 EUiLayoutBadControlType, |
|
54 EUiLayoutCandiateNumIsNotSet, |
|
55 EUiLayoutFuncNotImplemented, |
|
56 EUiLayoutBadKeyBmpIndex, |
|
57 EUiLayoutNoShadowBmp, |
|
58 EUiLayoutNoKey, |
|
59 EUiGeneralIndexError, |
|
60 EUiFullscreenWithoutHWRWnd, |
|
61 EUiLayoutBadParentType, |
|
62 EUiNullParam, |
|
63 EUiCursorNoOwner, |
|
64 EUiNoparent |
|
65 }; |
|
66 |
|
67 //define base control types |
|
68 //Derived class should not re-assign new ctrl type. |
|
69 enum TStockBaseCtrlType |
|
70 { |
|
71 ECtrlBaseCtrl = 0x0001, |
|
72 ECtrlTactileFeedback = 0x0002, |
|
73 ECtrlHwrWnd = 0x0004 | ECtrlBaseCtrl, //HWR writing window |
|
74 ECtrlTransparentHwrWnd = 0x0008 | ECtrlHwrWnd, //HWR transparent window |
|
75 ECtrlCandidateList = 0x0010 | ECtrlBaseCtrl, //Candidate list |
|
76 ECtrlButton = 0x0020 | ECtrlBaseCtrl | ECtrlTactileFeedback, //Button |
|
77 ECtrlDragBar = 0x0040 | ECtrlButton, //drag bar |
|
78 ECtrlControlGroup = 0x0080 | ECtrlBaseCtrl/* | ECtrlTactileFeedback*/, //control group |
|
79 // ECtrlButtonGroup = 0x0080 | ECtrlControlGroup, //button group |
|
80 ECtrlEditAreaBase = 0x0100 | ECtrlBaseCtrl | ECtrlTactileFeedback, //editor base |
|
81 ECtrlInputContextArea = 0x0200 | ECtrlEditAreaBase, //input context area |
|
82 ECtrlVirtualKeyboard = 0x0400 | ECtrlBaseCtrl, //virtual keyboard |
|
83 ECtrlPopupWindow = 0x0800 | ECtrlBaseCtrl, //pop up window |
|
84 ECtrlPopupChoiceList = 0x1000 | ECtrlPopupWindow | ECtrlTactileFeedback, //pop up choice list |
|
85 //ECtrlVirtualItutKeypad = 0x2000 | ECtrlVirtualKeyboard, |
|
86 ECtrlVirtualKey = 0x2000 | ECtrlBaseCtrl | ECtrlTactileFeedback, //virtual key control |
|
87 ECtrlVirtualItutKey = 0x4000 | ECtrlVirtualKey, //virtual itut key control |
|
88 ECtrlBackgroundCtrl = 0x8000, |
|
89 ECtrlCursor = 0x00010000 | ECtrlBaseCtrl, //editor cursor |
|
90 |
|
91 //Add more stock controls here. E.g ECtrlOskKey for VKB key |
|
92 ECtrlWndBasedCtrl = 0x00040000, |
|
93 EUserCtrlBase = 0x00080000 |
|
94 }; |
|
95 |
|
96 //button type |
|
97 enum TButtonBmpType |
|
98 { |
|
99 EBtnBmpNonActive , //bitmap for non active control |
|
100 EBtnBmpNonActivePressed, //bitmap for pressed active control, |
|
101 |
|
102 EBtnBmpActive, //bitmap for active control |
|
103 EBtnBmpActivePressed, //bitmap for pressed active control |
|
104 |
|
105 EBtnBmpDisabled, //bitmap for disabled control |
|
106 EBtnBmpDimmed = EBtnBmpDisabled, |
|
107 |
|
108 EBtnBmpMovingIndicator, |
|
109 |
|
110 EBtnBmpLastType = EBtnBmpMovingIndicator |
|
111 }; |
|
112 |
|
113 //control event type |
|
114 enum TControlEvent |
|
115 { |
|
116 EEventButtonDown, //for button |
|
117 EEventButtonUp, //for button |
|
118 EEventDraggingStart, //for drag bar |
|
119 EEventDragging, //for drag bar |
|
120 EEventDraggingEnd, //for drag bar |
|
121 EEventVirtualKeyUp, //for virtual key |
|
122 EEventVirtualKeyDown, //for virtual key |
|
123 EEventHwrStrokeStarted, //for hwr window |
|
124 EEventHwrStrokeFinished, //for hwr window |
|
125 EEventHwrCharacterTimerOut, //for hwr window |
|
126 EEventCandidateSelected, //for candidate window |
|
127 EEventButtonLongPress, //for dragbar long press event |
|
128 |
|
129 EEventSizeChanged, //for base control size change |
|
130 EEventRegionUpdated, //region has been updated |
|
131 |
|
132 EEventSetAppCursorSelection, //for app cursor selection changing |
|
133 |
|
134 EEventControlFocusGained, |
|
135 EEventControlFocusLost, |
|
136 |
|
137 //Cancel button down event, this happends when button up in another control |
|
138 EEventButtonDownCanceled, |
|
139 EEventHwrStrokeCanceled, |
|
140 |
|
141 EEventControlDestroyed, |
|
142 |
|
143 EEventChoiceSelected, |
|
144 EEventPointerLeftControl, //Pointer leaves a control after button down |
|
145 EEventPointerEnterControl, //pointer re-enters a control after button down |
|
146 |
|
147 EEventVirtualKeyLatched, //pointer down in a latched virtual key |
|
148 EEventVirtualKeyUnLatched, //point down in a unlatched virtaul key |
|
149 EEventICFSelectionChanged, //ICF selection has been changed |
|
150 EEventRawKeyDownEvent, //raw ITU-T key down event |
|
151 EEventRawKeyUpEvent, //raw ITU-T key up event |
|
152 EEventPointerDownOnNomatch, //pointer down on ICF nomatch range |
|
153 EEventPointerDownOnInline, // pointer down on ICF inline, but not in nomatch range |
|
154 EEventCapturePointer, |
|
155 EEventIcfPointerUpEvent, //Point up in icfevent |
|
156 EEventTooltipPointerUp, |
|
157 EEventTooltipPointerLeave, |
|
158 EEventTooltipPointerEnter, |
|
159 EEventCommitUnderLine, |
|
160 EEventInsertSpace, |
|
161 EEventControlExtBase = 1000, //extended event for common control |
|
162 EEventControlUserBase = 2000 //user event starts from here |
|
163 }; |
|
164 |
|
165 //shadow bitmap index |
|
166 /****************************************************************************/ |
|
167 // A shadow is drawn by 8 bitmaps. Their position is defined here |
|
168 // |
|
169 // tl tm tr |
|
170 // lm rm |
|
171 // bl bm br |
|
172 // |
|
173 /****************************************************************************/ |
|
174 |
|
175 enum TShadowBitmapIndex |
|
176 { |
|
177 KShadowBmpTl, //top left bitmap |
|
178 KShadowBmpTm, //top middle bitamp |
|
179 KShadowBmpTr, //top right bitmap |
|
180 |
|
181 KShadowBmpLm, //left middle bitmap |
|
182 KShadowBmpRm, //right middle bitmap |
|
183 |
|
184 KShadowBmpBl, //bottom left bitmap |
|
185 KShadowBmpBm, //bottom middle bitmap |
|
186 KShadowBmpBr, //bottom right bitmap |
|
187 }; |
|
188 |
|
189 /** |
|
190 * CFepUiBaseCtrl |
|
191 * |
|
192 * Base control for all FEP UI layout controls. |
|
193 * |
|
194 * @lib feplayoutcontrol.lib |
|
195 * @since S60 v4.0 |
|
196 */ |
|
197 class CFepUiBaseCtrl : public CBase, public MPositionObserver, |
|
198 public MOnResourceChangFunctions |
|
199 { |
|
200 friend class CControlGroup; |
|
201 friend class CInsertionPoint; |
|
202 public: |
|
203 enum TZOrder |
|
204 { |
|
205 EOrderBackground = 1500, //order for background control |
|
206 EOrderNomal = 1000, //default z-order for control |
|
207 EOrderFront = 500, // front order for control |
|
208 EOrderTopMost = 0 // for top most control |
|
209 }; |
|
210 |
|
211 public: |
|
212 /** |
|
213 * Constructor |
|
214 * |
|
215 * @since S60 V4.0 |
|
216 * @param aRect The rectangle area for this control |
|
217 * @param aUiLayout Ui layout who contains this control. Ownership not transferred |
|
218 * @param aControlId control Id |
|
219 */ |
|
220 IMPORT_C CFepUiBaseCtrl(const TRect& aRect,CFepUiLayout* aUiLayout, |
|
221 TInt aControlId); |
|
222 |
|
223 /** |
|
224 * Constructor. Used internally by CControlGroup |
|
225 * |
|
226 * @since S60 V4.0 |
|
227 * @param aControl The control to be added. The control must set its extent |
|
228 * before added to the layout. |
|
229 * @param aUiLayout Ui layout who contains this control. Ownership not transferred |
|
230 * @param aOwnership The ownership of the window control. ETrue if it's transfered |
|
231 * to this control |
|
232 */ |
|
233 CFepUiBaseCtrl(CCoeControl* aControl, CFepUiLayout* aUiLayout,TBool aOwnership = ETrue); |
|
234 |
|
235 /** |
|
236 * Do base contruction. Allocate event data buffer |
|
237 * Each derived control must call this in its contruction time |
|
238 * |
|
239 * @since S60 v4.0 |
|
240 */ |
|
241 IMPORT_C void BaseConstructL(); |
|
242 |
|
243 /** |
|
244 * Destructor. |
|
245 * |
|
246 * @since S60 V4.0 |
|
247 */ |
|
248 IMPORT_C virtual ~CFepUiBaseCtrl(); |
|
249 |
|
250 /** |
|
251 * Pure virtual function, draws the control |
|
252 * |
|
253 * @since S60 V4.0 |
|
254 */ |
|
255 IMPORT_C virtual void Draw(); |
|
256 |
|
257 /** |
|
258 * Redraws the content in a control |
|
259 * |
|
260 * @since S60 V4.0 |
|
261 * @param aRect The rect to be redrawed |
|
262 */ |
|
263 IMPORT_C virtual void ReDrawRect(const TRect& aRect); |
|
264 |
|
265 /** |
|
266 * Capture or release the pointer. |
|
267 * After capturing, all UI layout event will be processed by this control |
|
268 * |
|
269 * @since S60 V4.0 |
|
270 * @param aFlag The flag indicates capturing or releasing. |
|
271 * @return The control which captures the pointer before. |
|
272 */ |
|
273 IMPORT_C CFepUiBaseCtrl* CapturePointer(TBool aFlag = ETrue); |
|
274 |
|
275 /** |
|
276 * Clear the whole control area |
|
277 * |
|
278 * @since S60 V4.0 |
|
279 */ |
|
280 IMPORT_C void Clear(); |
|
281 |
|
282 /** |
|
283 * Clear a area in the control |
|
284 * |
|
285 * @since S60 V4.0 |
|
286 * @param aRect The rect to be cleared. |
|
287 */ |
|
288 IMPORT_C void ClearRect(const TRect& aRect); |
|
289 |
|
290 /** |
|
291 * Hide or shoe control. A hiden control will not handle the event. |
|
292 * |
|
293 * @since S60 V4.0 |
|
294 * @param aFlag ETrue if want to hide the control. |
|
295 */ |
|
296 IMPORT_C virtual void Hide(TBool aFlag); |
|
297 |
|
298 /** |
|
299 * Bring the control to top most in current control group and show it. |
|
300 * |
|
301 * @since S60 V5.0 |
|
302 */ |
|
303 IMPORT_C void BringToTop(); |
|
304 |
|
305 /** |
|
306 * Bring the control to back most in current control group and show it. |
|
307 * |
|
308 * @since S60 V5.0 |
|
309 */ |
|
310 IMPORT_C void BringToBack(); |
|
311 /* |
|
312 * Set background bitmap |
|
313 * |
|
314 * @since S60 V4.0 |
|
315 * @param aBmp The background bitmap. Ownership transferred to control |
|
316 */ |
|
317 IMPORT_C virtual void SetBackgroundBitmapL(CFbsBitmap* aBmp); |
|
318 |
|
319 /** |
|
320 * Set background mask bitmap |
|
321 * |
|
322 * @since S60 V4.0 |
|
323 * @param aBmp The background bitmap. Ownership transferred to control |
|
324 */ |
|
325 IMPORT_C virtual void SetBackgroundMaskBitmapL(CFbsBitmap* aBmp); |
|
326 |
|
327 /** |
|
328 * Check whether this control contains the point |
|
329 * |
|
330 * @since S60 V4.0 |
|
331 * @param aPoint The point to be checked |
|
332 * @return ETrue if control valid region contains the point, otherwise EFalse |
|
333 */ |
|
334 IMPORT_C virtual TBool Contains(const TPoint& aPt); |
|
335 |
|
336 /** |
|
337 * Set control's rectangle |
|
338 * |
|
339 * @since S60 V4.0 |
|
340 * @param aRect The new control area |
|
341 */ |
|
342 IMPORT_C virtual void SetRect(const TRect& aRect); |
|
343 |
|
344 /** |
|
345 * Set shadow rect. Shadow rect defines the outside rect of the control. |
|
346 * The shadow is drawn between this rect and control's rect using bitmaps |
|
347 * |
|
348 * @since S60 V4.0 |
|
349 * @param aRect The shadow rect. Shadow rect must bigger than control's |
|
350 * rect, otherwise no effect. |
|
351 */ |
|
352 IMPORT_C void SetShadowRect(const TRect& aRect); |
|
353 |
|
354 /** |
|
355 * Set shadow rect for a shadow area. |
|
356 * The nth shadow is drawn in this shadow rect |
|
357 * |
|
358 * @since S60 V4.0 |
|
359 * @param aRect The shadow rect. |
|
360 * @param aIndex The index position for shadow rect |
|
361 */ |
|
362 IMPORT_C void SetShadowAreaRect(const TRect& aRect, TShadowBitmapIndex aIndex); |
|
363 |
|
364 /** |
|
365 * Add event obeserver. |
|
366 * The observer will get notified when control event happens. |
|
367 * |
|
368 * @since S60 V4.0 |
|
369 * @param aObserver An event obeserver. Ownership not transferred |
|
370 */ |
|
371 IMPORT_C void AddEventObserver(MEventObserver* aObserver); |
|
372 |
|
373 /** |
|
374 * Remove event obeserver |
|
375 * |
|
376 * @since S60 V4.0 |
|
377 * @param aObserver An event obeserver to be removed. |
|
378 */ |
|
379 IMPORT_C void RemoveEventObserver(MEventObserver* aObserver); |
|
380 |
|
381 /** |
|
382 * Report event to event observer |
|
383 * |
|
384 * @since S60 V4.0 |
|
385 * @param aEventType the event type |
|
386 * @param aEventData Event data |
|
387 */ |
|
388 IMPORT_C void ReportEvent(TInt aEventType, const TDesC& aEventData = KNullDesC); |
|
389 |
|
390 /** |
|
391 * Update control's valid region when other control hiding or displaying. |
|
392 * This is usually used for HWR window to change it's writing area. |
|
393 * |
|
394 * @since S60 V4.0 |
|
395 * @param aCtrl The control whose displaying status changed |
|
396 * @param bFlag ETrue if control is hiden, otherwise EFalse |
|
397 */ |
|
398 IMPORT_C virtual void UpdateValidRegion(CFepUiBaseCtrl* aCtrl,TBool aRemoveFlag); |
|
399 |
|
400 /** |
|
401 * Move conntrol |
|
402 * |
|
403 * @since S60 V4.0 |
|
404 * @param aOffset The offset to be moved |
|
405 */ |
|
406 IMPORT_C virtual void Move(const TPoint& aOffset); |
|
407 |
|
408 /** |
|
409 * Set control active |
|
410 * |
|
411 * @since S60 V4.0 |
|
412 * @param aFlag The active flag. ETrue if active, otherwise EFalse |
|
413 */ |
|
414 IMPORT_C virtual void SetActive(TBool aFlag); |
|
415 |
|
416 |
|
417 /** |
|
418 * Handle pointer down event |
|
419 * |
|
420 * @since S60 V4.0 |
|
421 * @param aPoint The point position relative the layout |
|
422 * @return The control which handles the event. |
|
423 */ |
|
424 IMPORT_C virtual CFepUiBaseCtrl* HandlePointerDownEventL(const TPoint& aPoint); |
|
425 |
|
426 /** |
|
427 * Handle pointer move event |
|
428 * |
|
429 * @since S60 V4.0 |
|
430 * @param aPoint The point position relative the layout |
|
431 * @return The control which handles the event. |
|
432 */ |
|
433 IMPORT_C virtual CFepUiBaseCtrl* HandlePointerMoveEventL(const TPoint& aPoint); |
|
434 |
|
435 /** |
|
436 * Handle pointer up event |
|
437 * |
|
438 * @since S60 V4.0 |
|
439 * @param aPoint The point position relative the layout |
|
440 * @return The control which handles the event. |
|
441 */ |
|
442 IMPORT_C virtual CFepUiBaseCtrl* HandlePointerUpEventL(const TPoint& aPoint); |
|
443 |
|
444 |
|
445 /** |
|
446 * Cancel pointer down event. |
|
447 * This will be called when a control has pointer down but pointer up |
|
448 * event happens in other ways. If overrided, this base implementation |
|
449 * must be called in order to report the event. |
|
450 * |
|
451 * @since S60 V4.0 |
|
452 * @param aFocusedFlag ETrue if got focused, otherwise EFalse |
|
453 */ |
|
454 IMPORT_C virtual void CancelPointerDownL(); |
|
455 |
|
456 /** |
|
457 * Handle pointer levae event. |
|
458 * This will be called only when it's got pointer down event before and |
|
459 * now pointer leaves without pointer up event |
|
460 * |
|
461 * @since S60 V4.0 |
|
462 * @param aPoint current pointer position |
|
463 */ |
|
464 IMPORT_C virtual void HandlePointerLeave(const TPoint& aPoint); |
|
465 |
|
466 /** |
|
467 * Handle pointer enter event. |
|
468 * This will be called only when it's got pointer down event before and |
|
469 * pointer leaves but now comes back without pointer up event. |
|
470 * |
|
471 * @since S60 V4.0 |
|
472 * @param aPoint current pointer position |
|
473 */ |
|
474 IMPORT_C virtual void HandlePointerEnter(const TPoint& aPoint); |
|
475 |
|
476 |
|
477 /** |
|
478 * Register to layout to require updaing control valid region constantly. |
|
479 * |
|
480 * @since S60 v4.0 |
|
481 * @param aRequiredFlag Register or deregister. ETrue if register. |
|
482 */ |
|
483 IMPORT_C void RequireRegionUpdateL(TBool aRequiredFlag); |
|
484 |
|
485 /** |
|
486 * Set Tactile Feedback Type |
|
487 * Advanced Tactile feedback REQ417-47932 |
|
488 * |
|
489 * @since S60 v4.0 |
|
490 * @param aTactileType. |
|
491 */ |
|
492 IMPORT_C void SetTactileFeedbackType(TInt aTactileType); |
|
493 |
|
494 /** |
|
495 * Return control type |
|
496 * |
|
497 * @since S60 V4.0 |
|
498 * @return The control type |
|
499 */ |
|
500 inline TControlType ControlType(); |
|
501 |
|
502 /** |
|
503 * Return tactile feedback type |
|
504 * |
|
505 * Advanced Tactile feedback REQ417-47932 |
|
506 * @return the tactile feedback type |
|
507 */ |
|
508 inline TInt TactileFeedbackType() const; |
|
509 |
|
510 |
|
511 /** |
|
512 * Get control Id |
|
513 * |
|
514 * @since S60 V4.0 |
|
515 * @return The control id |
|
516 */ |
|
517 inline TInt ControlId(); |
|
518 |
|
519 /** |
|
520 * Get control size in rect |
|
521 * |
|
522 * @since S60 V4.0 |
|
523 * @return The control size in rect |
|
524 */ |
|
525 inline const TRect& Rect(); |
|
526 |
|
527 /** |
|
528 * Get valid region. A valid region is that the region responds to pointer. |
|
529 * |
|
530 * @since S60 V4.0 |
|
531 * @return The control valid region |
|
532 */ |
|
533 inline const RRegion& Region(); |
|
534 /** |
|
535 * Set background color |
|
536 * |
|
537 * @since S60 V4.0 |
|
538 * @param aCol Background color to be used |
|
539 */ |
|
540 inline void SetBkColor(const TRgb& aCol); |
|
541 |
|
542 /** |
|
543 * Set mask background color |
|
544 * |
|
545 * @since S60 V4.0 |
|
546 * @param aCol The mask back ground color |
|
547 */ |
|
548 inline void SetMaskBkCol(const TRgb& aCol); |
|
549 |
|
550 /** |
|
551 * Set pen size |
|
552 * |
|
553 * @since S60 V4.0 |
|
554 * @param aSize New pen size |
|
555 */ |
|
556 inline void SetPenSize(const TSize& aSize); |
|
557 |
|
558 /** |
|
559 * Get pen size |
|
560 * |
|
561 * @since S60 V4.0 |
|
562 * @return Pen size |
|
563 */ |
|
564 inline const TSize& PenSize(); |
|
565 |
|
566 /** |
|
567 * Set pen color |
|
568 * |
|
569 * @since S60 V4.0 |
|
570 * @param aCol New pen color |
|
571 */ |
|
572 inline void SetPenColor(const TRgb& aCol) ; |
|
573 |
|
574 /** |
|
575 * Set border size |
|
576 * |
|
577 * @since S60 V4.0 |
|
578 * @param aSize New border size |
|
579 */ |
|
580 inline void SetBorderSize(const TSize& aSize); |
|
581 |
|
582 /** |
|
583 * Get border size |
|
584 * |
|
585 * @since S60 V4.0 |
|
586 * @return Border size |
|
587 */ |
|
588 inline const TSize& BorderSize(); |
|
589 |
|
590 /** |
|
591 * Set pen color |
|
592 * |
|
593 * @since S60 V4.0 |
|
594 * @param aCol New border color |
|
595 */ |
|
596 inline void SetBorderColor(const TRgb& aCol) ; |
|
597 |
|
598 |
|
599 /** |
|
600 * Get pen color |
|
601 * |
|
602 * @since S60 V4.0 |
|
603 * @return border color |
|
604 */ |
|
605 inline const TRgb& BorderColor() ; |
|
606 |
|
607 /** |
|
608 * Get hide flag |
|
609 * |
|
610 * @since S60 V4.0 |
|
611 * @return ETrue if control is hiden, otherwise EFalse |
|
612 */ |
|
613 inline TBool Hiden(); |
|
614 |
|
615 /** |
|
616 * Get initialization status |
|
617 * |
|
618 * @since S60 V4.0 |
|
619 * @return Control initialization status. ETrue if initialized, otherwise EFalse. |
|
620 */ |
|
621 inline TBool Ready(); |
|
622 |
|
623 /** |
|
624 * set control drawing status. It won't be drawn if not ready |
|
625 * |
|
626 * @since S60 V4.0 |
|
627 * @param aReadyFlag The control ready flag |
|
628 */ |
|
629 inline void SetReady(TBool aReadyFlag); |
|
630 |
|
631 /** |
|
632 * Test whether the control belongs one kind of control class |
|
633 * |
|
634 * @since S60 V4.0 |
|
635 * @param aCtrlClass The control class type |
|
636 * @return ETrue if the control belongs to the class, otherwise EFalse |
|
637 */ |
|
638 inline TBool IsKindOfControl(TStockBaseCtrlType aCtrlClass); |
|
639 |
|
640 |
|
641 /** |
|
642 * Get active status |
|
643 * |
|
644 * @since S60 V4.0 |
|
645 * @return active status |
|
646 */ |
|
647 inline TBool IsActive(); |
|
648 |
|
649 /** |
|
650 * Set control type |
|
651 * |
|
652 * @since S60 V4.0 |
|
653 * @param aCtrlType The control type |
|
654 */ |
|
655 inline void SetControlType(TControlType aCtrlType); |
|
656 |
|
657 /** |
|
658 * get control pointer down status |
|
659 * |
|
660 * @since S60 V4.0 |
|
661 * @return The pointer down status. ETrue if has pointer down |
|
662 */ |
|
663 inline TBool PointerDown(); |
|
664 |
|
665 /** |
|
666 * change control pointer down status |
|
667 * |
|
668 * @since S60 V4.0 |
|
669 * @param aFlag The pointer down flag. |
|
670 */ |
|
671 inline void SetPointerDown(TBool aFlag); |
|
672 |
|
673 |
|
674 /** |
|
675 * Set control valid region |
|
676 * |
|
677 * @since S60 V4.0 |
|
678 * @param aRegion The new control region |
|
679 */ |
|
680 inline void SetRegion(const RRegion& aRegion); |
|
681 |
|
682 /** |
|
683 * Tell whether it allows other control moving on top of it |
|
684 * |
|
685 * @since S60 V4.0 |
|
686 * @return Overlap flag |
|
687 */ |
|
688 inline TBool AllowOverlap(); |
|
689 |
|
690 /** |
|
691 * Set overlap flag |
|
692 * |
|
693 * @since S60 V4.0 |
|
694 * @param aFlag The new overlap falg |
|
695 */ |
|
696 inline void SetAllowOverlap(TBool aFlag); |
|
697 |
|
698 |
|
699 // from base class MPositionObserver |
|
700 |
|
701 /** |
|
702 * From MPositionObserver |
|
703 * Handle position change event. |
|
704 * It's called to change the position after it's being dragging |
|
705 * |
|
706 * @since S60 V4.0 |
|
707 * @param aOffset The moving offset |
|
708 * @return The flag whether this observer has processed the event. ETrue if processed. |
|
709 */ |
|
710 IMPORT_C TBool HandlePositionChange(const TPoint& aOffset); |
|
711 |
|
712 /** |
|
713 * From MPositionObserver |
|
714 * Get observer's area to be moved when position changed |
|
715 * |
|
716 * @since S60 V4.0 |
|
717 * @return The rect of observer's moving area |
|
718 */ |
|
719 IMPORT_C const TRect& MovingArea(); |
|
720 |
|
721 /** |
|
722 * From MPositionObserver |
|
723 * Tell whether this observer is a fep base control |
|
724 * |
|
725 * @since S60 v4.0 |
|
726 * @return ETrue if this observer is a control, otherwise, EFalse. |
|
727 */ |
|
728 IMPORT_C TBool IsFepBaseControl(); |
|
729 |
|
730 /** |
|
731 * Get shadow rect |
|
732 * @since S60 V4.0 |
|
733 * @return control shadow rect |
|
734 */ |
|
735 inline const TRect& ShadowRect(); |
|
736 |
|
737 /** |
|
738 * set control shadow bitmap and mask bmp |
|
739 * @since S60 V4.0 |
|
740 * @param The shadow background bitmap. Ownership transferred |
|
741 * @param The shadow background mask bitmap. Ownership transferred |
|
742 * @param aIndex The shadow bitmap position index |
|
743 */ |
|
744 IMPORT_C void SetShadowBmp(CFbsBitmap* aBmp,CFbsBitmap* aMaskBmp, |
|
745 TShadowBitmapIndex aIndex); |
|
746 |
|
747 /** |
|
748 * OnActivate. Called when the layout is going to be shown. |
|
749 * |
|
750 * @since S60 v4.0 |
|
751 */ |
|
752 IMPORT_C virtual void OnActivate(); |
|
753 |
|
754 /** |
|
755 * OnDeActivate. Called when the layout is going to be hidden |
|
756 * |
|
757 * @since S60 v4.0 |
|
758 */ |
|
759 IMPORT_C virtual void OnDeActivate(); |
|
760 /** |
|
761 * Update layout area, cause screen update. However the updating is buffered until |
|
762 * refresh timer time out. |
|
763 * |
|
764 * @since S60 V4.0 |
|
765 * @param aRect the rect to be flushed in screen |
|
766 * @param aUpdateFlag ETrue if full update. |
|
767 */ |
|
768 IMPORT_C void UpdateArea(const TRect& aRect,TBool aUpdateFlag= EFalse); |
|
769 |
|
770 /** |
|
771 * Update layout area immediately |
|
772 * |
|
773 * @since S60 V4.0 |
|
774 * @param aRect the rect to be flushed in screen |
|
775 * @param aUpdateFlag ETrue if full update. |
|
776 */ |
|
777 IMPORT_C void UpdateAreaImmed(const TRect& aRect,TBool aUpdateFlag= EFalse); |
|
778 |
|
779 /** |
|
780 * Get shadow area rect |
|
781 * |
|
782 * @since S60 V4.0 |
|
783 * @param aIndex The index for shadow rect |
|
784 */ |
|
785 inline TRect ShadowAreaRect(TShadowBitmapIndex aIndex); |
|
786 |
|
787 /** |
|
788 * Call back function when layout starts dragging |
|
789 * |
|
790 * @since S60 V4.0 |
|
791 */ |
|
792 IMPORT_C virtual void OnLayoutDraggingStart(); |
|
793 |
|
794 /** |
|
795 * Call back function when layout ends dragging |
|
796 * |
|
797 * @since S60 V4.0 |
|
798 */ |
|
799 IMPORT_C virtual void OnLayoutDraggingEnd(); |
|
800 |
|
801 /** |
|
802 * Get window based control |
|
803 * |
|
804 * @since S60 V4.0 |
|
805 * @return The window based control associated with this control |
|
806 */ |
|
807 inline CCoeControl* WndBasedControl(); |
|
808 |
|
809 // from base class MOnResourceChangFunctions |
|
810 |
|
811 /** |
|
812 * From MOnResourceChangFunctions |
|
813 * Set resource Id |
|
814 * |
|
815 * @since S60 V4.0 |
|
816 * @param aResId The resource id; |
|
817 */ |
|
818 IMPORT_C void SetResourceId(TInt32 aResId); |
|
819 |
|
820 /** |
|
821 * Get hide flag |
|
822 * |
|
823 * @since S60 V4.0 |
|
824 * @return ETrue if all controls are hiden, otherwise EFalse |
|
825 */ |
|
826 IMPORT_C TBool WholeHiden(); |
|
827 |
|
828 /** |
|
829 * From MOnResourceChangFunctions |
|
830 * Construct from resource |
|
831 * |
|
832 * @since S60 V4.0 |
|
833 */ |
|
834 IMPORT_C void ConstructFromResourceL(); |
|
835 |
|
836 /** |
|
837 * Get resource Id |
|
838 * |
|
839 * @since S60 V4.0 |
|
840 * @return The resource id; |
|
841 */ |
|
842 inline TInt32 ResourceId(); |
|
843 |
|
844 IMPORT_C void SetParent(CFepUiBaseCtrl* aParent); |
|
845 |
|
846 inline CFepUiBaseCtrl* ParentCtrl(); |
|
847 |
|
848 /** |
|
849 * Get the associated CCoeControl control |
|
850 * |
|
851 * @since S60 V5.0 |
|
852 * @return The CCoeControl it contains; |
|
853 */ |
|
854 inline CCoeControl* WndControl(); |
|
855 |
|
856 /** |
|
857 * Simulates a internal raw event. The event is handled inside pen input ui, |
|
858 * will not go for window server. |
|
859 * |
|
860 * @since S60 V5.0 |
|
861 * @param aPtEvent The simulated raw event |
|
862 */ |
|
863 IMPORT_C void SimulateRawEvent(const TRawEvent& aEvent); |
|
864 |
|
865 IMPORT_C void SetOrdinalPos(TInt aPos); |
|
866 |
|
867 inline TInt OrderPos() const; |
|
868 |
|
869 TInt AbsOrderPos(); |
|
870 |
|
871 /** |
|
872 * Check whether this control is on top of another control. If a control is on top of another |
|
873 * it will draw later so it will overwrite the overlapped area. |
|
874 * |
|
875 * @since S60 V5.0 |
|
876 * @param aCtrl The compared control |
|
877 * @return ETrue if this control is on top of the specified one. |
|
878 */ |
|
879 TBool IsOnTopOf(CFepUiBaseCtrl* aCtrl); |
|
880 |
|
881 /** |
|
882 * Check whether this control has overlapped area with another one |
|
883 * |
|
884 * @since S60 V5.0 |
|
885 * @param aCtrl The compared control |
|
886 * @return ETrue if this control has overlapped area with the specified one. |
|
887 */ |
|
888 TBool Overlapped(CFepUiBaseCtrl* aCtrl); |
|
889 |
|
890 /** |
|
891 * Compare order pos |
|
892 * |
|
893 * @since S60 V5.0 |
|
894 * @return ETrue if this control is on top of the specified one. |
|
895 */ |
|
896 TBool CompareOrder(CFepUiBaseCtrl* aCtrl); |
|
897 |
|
898 |
|
899 /** |
|
900 * Compare order pos for two control within the same control grop |
|
901 * |
|
902 * @since S60 V5.0 |
|
903 * @return ETrue if this control is on top of the specified one. |
|
904 */ |
|
905 TBool CompareOrderInSameGroup(CFepUiBaseCtrl* aCtrl); |
|
906 |
|
907 protected: |
|
908 |
|
909 /** |
|
910 * Draw bitmap to control rect |
|
911 * |
|
912 * @param aBitmap The given bitmap |
|
913 * @param aStretchFlag The flag tells whether this bitmap should be stretched |
|
914 */ |
|
915 IMPORT_C void DrawBitmap(const CFbsBitmap* aBitmap,TBool aStretchFlag); |
|
916 |
|
917 /** |
|
918 * Draw bitmap to control rect |
|
919 * |
|
920 * @param aRect The drawn rect |
|
921 * @param aBitmap The given bitmap |
|
922 * @param aStretchFlag The flag tells whether this bitmap should be stretched |
|
923 */ |
|
924 IMPORT_C void DrawBitmap(const TRect aRect, const CFbsBitmap* aBitmap,TBool aStretchFlag); |
|
925 |
|
926 /** |
|
927 * Get background color |
|
928 * |
|
929 * @since S60 V4.0 |
|
930 * @return Background color |
|
931 */ |
|
932 inline const TRgb& BkColor(); |
|
933 |
|
934 /** |
|
935 * get mask background color |
|
936 * |
|
937 * @since S60 V4.0 |
|
938 * @return The mask back ground color |
|
939 */ |
|
940 inline const TRgb& MaskBkCol(); |
|
941 |
|
942 /** |
|
943 * Get pen color |
|
944 * @since S60 V4.0 |
|
945 * @return Pen colore |
|
946 */ |
|
947 inline const TRgb& PenColor(); |
|
948 |
|
949 /** |
|
950 * Get Ui layout |
|
951 * |
|
952 * @since S60 V4.0 |
|
953 * @return The ui layout |
|
954 */ |
|
955 inline CFepUiLayout* UiLayout(); |
|
956 |
|
957 /** |
|
958 * Get ui layout root control |
|
959 * |
|
960 * @since S60 v4.0 |
|
961 * @param aPos The new position. |
|
962 */ |
|
963 inline CFepUiLayoutRootCtrl* RootControl(); |
|
964 |
|
965 /** |
|
966 * get graphics context for sprite or window |
|
967 * @since S60 V4.0 |
|
968 * @return The graphic context |
|
969 */ |
|
970 inline CBitmapContext* BitGc(); |
|
971 |
|
972 /** |
|
973 * get Bitmap device for sprite or window |
|
974 * @since S60 V4.0 |
|
975 * @return The bitmap device |
|
976 */ |
|
977 inline CFbsBitmapDevice* BitmapDevice(); |
|
978 |
|
979 /** |
|
980 * get Mask bitmap device for sprite or window |
|
981 * @since S60 V4.0 |
|
982 * @return The mask bitmap device |
|
983 */ |
|
984 inline CFbsBitmapDevice* MaskBitmapDevice(); |
|
985 |
|
986 /** |
|
987 * get control background mask bmp |
|
988 * @since S60 V4.0 |
|
989 * @return The background mask bitmap |
|
990 */ |
|
991 inline CFbsBitmap* BkMaskBmp(); |
|
992 |
|
993 /** |
|
994 * get control background bmp |
|
995 * @since S60 V4.0 |
|
996 * @return The background bitmap |
|
997 */ |
|
998 inline CFbsBitmap* BackgroundBmp(); |
|
999 |
|
1000 /** |
|
1001 * set control background bmp |
|
1002 * @since S60 V4.0 |
|
1003 * @param The background bitmap to be set. Ownership transferred. |
|
1004 */ |
|
1005 inline void SetBackgroundBmp(CFbsBitmap* aBmp); |
|
1006 |
|
1007 /** |
|
1008 * set control background mask bmp |
|
1009 * @since S60 V4.0 |
|
1010 * @param The background mask bitmap to be set. Ownership transferred |
|
1011 */ |
|
1012 inline void SetBackgroundMaskBmp(CFbsBitmap* aBmp); |
|
1013 /** |
|
1014 * Draw shadow |
|
1015 * |
|
1016 * @since S60 V4.0 |
|
1017 */ |
|
1018 IMPORT_C void DrawShadow(); |
|
1019 |
|
1020 /** |
|
1021 * Do base contruction. Allocate event data buffer |
|
1022 * Each derived control must call this in its contruction time |
|
1023 * |
|
1024 * @since S60 v4.0 |
|
1025 * @param aRoot The root control. |
|
1026 */ |
|
1027 void BaseConstructL(CFepUiLayoutRootCtrl* aRoot); |
|
1028 |
|
1029 /** |
|
1030 * Draw mask background |
|
1031 * |
|
1032 * @since S60 v4.0 |
|
1033 * @param aBmpStretchFlag Flag tells whether the bitmap will be stretched |
|
1034 * to fit the rect. Default value is ETrue. |
|
1035 */ |
|
1036 IMPORT_C void DrawMaskBackground(TBool aBmpStretchFlag = ETrue); |
|
1037 |
|
1038 /** |
|
1039 * Draw opaque mask background. Draw an opaque ground. |
|
1040 * |
|
1041 * @since S60 v4.0 |
|
1042 * @param aBmpStretchFlag Flag tells whether the bitmap will be stretched |
|
1043 * to fit the rect. Default value is ETrue. |
|
1044 */ |
|
1045 IMPORT_C void DrawOpaqueMaskBackground(TBool aBmpStretchFlag = ETrue); |
|
1046 |
|
1047 /** |
|
1048 * Draw opaque mask background. Draw an opaque ground. |
|
1049 * |
|
1050 * @since S60 v4.0 |
|
1051 * @param aBmpStretchFlag Flag tells whether the bitmap will be stretched |
|
1052 * @param aRect Rect to be draw |
|
1053 * to fit the rect. Default value is ETrue. |
|
1054 */ |
|
1055 IMPORT_C void DrawOpaqueMaskBackground(const TRect aRect, TBool aBmpStretchFlag = ETrue); |
|
1056 |
|
1057 /** |
|
1058 * Draw transparent mask background |
|
1059 * |
|
1060 * @since S60 v4.0 |
|
1061 * @param aBmpStretchFlag Flag tells whether the bitmap will be stretched |
|
1062 * to fit the rect. Default value is ETrue. |
|
1063 */ |
|
1064 IMPORT_C void DrawTransparentMaskBackground(const TRect& aRect, TBool aBmpStretchFlag = ETrue); |
|
1065 |
|
1066 /** |
|
1067 * Draw background. |
|
1068 * |
|
1069 * @since S60 v4.0 |
|
1070 * @param aBmpStretchFlag Flag tells whether the bitmap will be stretched |
|
1071 * to fit the rect. Default value is ETrue. |
|
1072 */ |
|
1073 IMPORT_C void DrawBackground(TBool aBmpStretchFlag = ETrue); |
|
1074 |
|
1075 /** |
|
1076 * Draw background. |
|
1077 * |
|
1078 * @since S60 v4.0 |
|
1079 * @param aBmpStretchFlag Flag tells whether the bitmap will be stretched |
|
1080 * @param aRect Rect to be draw |
|
1081 * to fit the rect. Default value is ETrue. |
|
1082 */ |
|
1083 IMPORT_C void DrawBackground(const TRect aRect,TBool aBmpStretchFlag = ETrue); |
|
1084 |
|
1085 /** |
|
1086 * Test whether control is able to be drawn. e.g, is ready or shown? |
|
1087 * |
|
1088 * @since S60 v4.0 |
|
1089 * @return ETrue if able to be drawn. |
|
1090 */ |
|
1091 IMPORT_C TBool AbleToDraw(); |
|
1092 |
|
1093 /** |
|
1094 * Draw background to device |
|
1095 * |
|
1096 * @since S60 v4.0 |
|
1097 * @param aRect The device rect to be filled. |
|
1098 * @param aDevie The device to be drawn |
|
1099 * @param aBmp The background bmp |
|
1100 * @param aBrushCol The brush color |
|
1101 * @param aPenCol The pen color |
|
1102 * @param aBmpStretchFlag The stretch flag for drawing bitmap. |
|
1103 */ |
|
1104 void DrawBackgroundToDevice(TRect aRect,CFbsDevice *aDevice, CFbsBitmap* aBmp, |
|
1105 const TRgb& aBrushCol, const TRgb& aPenCol,TBool aBmpStretchFlag); |
|
1106 |
|
1107 /** |
|
1108 * Enable region update |
|
1109 * |
|
1110 * @since S60 v5.0 |
|
1111 */ |
|
1112 inline void EnableRegionUpdating(); |
|
1113 |
|
1114 /** |
|
1115 * Enable region update |
|
1116 * |
|
1117 * @since S60 v5.0 |
|
1118 */ |
|
1119 inline void DisableRegionUpdating(); |
|
1120 |
|
1121 /** |
|
1122 * Get the clip region |
|
1123 * |
|
1124 * @since S60 v5.0 |
|
1125 * @return The clip region |
|
1126 */ |
|
1127 IMPORT_C const TRegion& ValidClipRegion(); |
|
1128 |
|
1129 //From CBase |
|
1130 /** |
|
1131 * Get the extension |
|
1132 * |
|
1133 * @since S60 v5.0 |
|
1134 * @param aExtensionId Extension UID |
|
1135 * @param a0 The extension returned |
|
1136 * @param a1 Any passed in parameter. |
|
1137 * @return Operation result. Implementation dependent |
|
1138 */ |
|
1139 virtual IMPORT_C TInt Extension_(TUint aExtensionId, TAny *&a0, TAny *a1); |
|
1140 /** |
|
1141 * Handle system resource change |
|
1142 * |
|
1143 * @since S60 V5.0 |
|
1144 * @param aType The system resource change type |
|
1145 */ |
|
1146 virtual IMPORT_C void HandleResourceChange(TInt aType); |
|
1147 |
|
1148 /** |
|
1149 * Handle pen UI graphic device size change event |
|
1150 * |
|
1151 * @since S60 V5.0 |
|
1152 */ |
|
1153 virtual IMPORT_C void GraphicDeviceSizeChanged(); |
|
1154 |
|
1155 inline void SetHidenFlag(TBool aFlag); |
|
1156 private: |
|
1157 /** |
|
1158 * Draw shadow bitmap |
|
1159 * |
|
1160 * @since S60 V4.0 |
|
1161 * @param aRect The rect to be drawn |
|
1162 * @param aIndex The shadow bitmap position index |
|
1163 */ |
|
1164 void DrawShadowBitmap(const TRect& aRect,TInt aIndex); |
|
1165 |
|
1166 protected: |
|
1167 /** |
|
1168 * Indicate whether the pointer has leaved a control |
|
1169 */ |
|
1170 TBool iPointerLeft; |
|
1171 /** |
|
1172 * Control rect. It's relative to ui layout |
|
1173 */ |
|
1174 TRect iRect; |
|
1175 |
|
1176 /** |
|
1177 * Control shadow rect. It's relative to ui layout |
|
1178 */ |
|
1179 TRect iShadowRect; |
|
1180 |
|
1181 /** |
|
1182 * Shadow area rect |
|
1183 */ |
|
1184 TRect iShadowAreaRect[KShadowBitmapTotalNum]; |
|
1185 |
|
1186 /** |
|
1187 * CCoeControl based control |
|
1188 * Own |
|
1189 */ |
|
1190 CCoeControl* iWndControl; |
|
1191 |
|
1192 /** |
|
1193 * The resource Id associatied with this control |
|
1194 */ |
|
1195 TInt32 iResourceId; |
|
1196 |
|
1197 /** |
|
1198 * Control border color |
|
1199 */ |
|
1200 TRgb iBorderColor; |
|
1201 |
|
1202 /** |
|
1203 * Control border size |
|
1204 */ |
|
1205 TSize iBorderSize; |
|
1206 |
|
1207 /** |
|
1208 * Valid region which reacts to the pointer event |
|
1209 */ |
|
1210 RRegion iValidRegion; |
|
1211 |
|
1212 /** |
|
1213 * Parent control |
|
1214 * Not own |
|
1215 */ |
|
1216 CFepUiBaseCtrl* iParentCtrl; |
|
1217 |
|
1218 /** |
|
1219 * Flag indicates whether rect changed should report to parent |
|
1220 */ |
|
1221 TBool iUpdateFlagEnabled; |
|
1222 |
|
1223 /** |
|
1224 * The actual drawing region. so drawing won't happend outside of the region. |
|
1225 */ |
|
1226 RRegion iClipRegion; |
|
1227 |
|
1228 private: |
|
1229 /** |
|
1230 * Control id |
|
1231 */ |
|
1232 TInt iControlId; |
|
1233 /** |
|
1234 * Control type. |
|
1235 * User derivated control should starts from EUserCtrlBase |
|
1236 */ |
|
1237 TControlType iControlType; |
|
1238 |
|
1239 /** |
|
1240 * Background color |
|
1241 */ |
|
1242 TRgb iBackgroundCol; |
|
1243 |
|
1244 /** |
|
1245 * Maks backgroud color |
|
1246 */ |
|
1247 TRgb iMaskBkCol; |
|
1248 |
|
1249 /** |
|
1250 * pen size |
|
1251 */ |
|
1252 TSize iPenSize; |
|
1253 |
|
1254 /** |
|
1255 * Pen color |
|
1256 */ |
|
1257 TRgb iPenColor; |
|
1258 |
|
1259 /** |
|
1260 * Flag indicates whether the control is hiden |
|
1261 */ |
|
1262 TBool iHiden; |
|
1263 |
|
1264 /* |
|
1265 * Event type of current event |
|
1266 */ |
|
1267 TEventType iEventType; |
|
1268 |
|
1269 /** |
|
1270 * flag to show whether pen has beed pressed down in this control |
|
1271 */ |
|
1272 TBool iPointerDown; |
|
1273 |
|
1274 /** |
|
1275 * flag to indicate whehter this control is ready to drawn |
|
1276 */ |
|
1277 TBool iReady; |
|
1278 |
|
1279 |
|
1280 /** |
|
1281 * control active status. |
|
1282 */ |
|
1283 TBool iIsActive; |
|
1284 |
|
1285 /** |
|
1286 * Flag tells whether a draging component can be moved on top of this control |
|
1287 */ |
|
1288 TBool iAllowOverlap; |
|
1289 |
|
1290 /** |
|
1291 * event observer list |
|
1292 */ |
|
1293 RPointerArray<MEventObserver> iEventObserverList; |
|
1294 |
|
1295 //pointer members |
|
1296 |
|
1297 /** |
|
1298 * Background bitmap |
|
1299 * Own. |
|
1300 */ |
|
1301 CFbsBitmap* iBackgroundBmp; |
|
1302 |
|
1303 /** |
|
1304 * Background mask bitmap |
|
1305 * Own. |
|
1306 */ |
|
1307 CFbsBitmap* iBkMaskBmp; |
|
1308 |
|
1309 /** |
|
1310 * The ui layout which contains this control |
|
1311 * Not own. |
|
1312 */ |
|
1313 CFepUiLayout* iUiLayout; |
|
1314 |
|
1315 /** |
|
1316 * Root control. It's a control group. |
|
1317 * Not Own |
|
1318 */ |
|
1319 CFepUiLayoutRootCtrl* iRootCtrl; |
|
1320 /** |
|
1321 * Shadow bitmaps. |
|
1322 * Own |
|
1323 */ |
|
1324 CFbsBitmap* iShadowBmp[2*KShadowBitmapTotalNum+1]; |
|
1325 |
|
1326 /** |
|
1327 * Layout owner |
|
1328 * Not own |
|
1329 */ |
|
1330 MLayoutOwner* iLayoutOwner; |
|
1331 |
|
1332 /** |
|
1333 * Ownership of the window control. If true, it will delete the window control during |
|
1334 * destruction. |
|
1335 */ |
|
1336 TBool iOwnWndCtrl; |
|
1337 |
|
1338 |
|
1339 //When pop up shown, the locked area will be also reduced from control. |
|
1340 RRegion iClipRegionWithoutLockedArea; |
|
1341 |
|
1342 |
|
1343 TInt iOrdinalPos; |
|
1344 /** |
|
1345 * Reservered |
|
1346 */ |
|
1347 TInt iReservered1; |
|
1348 |
|
1349 /** |
|
1350 * Reservered |
|
1351 */ |
|
1352 TInt iReservered2; |
|
1353 |
|
1354 NONSHARABLE_CLASS(CFepUiBaseCtrlExtension) |
|
1355 { |
|
1356 public: |
|
1357 |
|
1358 CFepUiBaseCtrlExtension(TInt aTactileType); |
|
1359 |
|
1360 /** |
|
1361 * Set Tactile Feedback Type |
|
1362 * Advanced Tactile feedback REQ417-47932 |
|
1363 */ |
|
1364 void SetTactileFeedbackType(TInt aTactileType); |
|
1365 |
|
1366 /** |
|
1367 * Return tactile feedback type |
|
1368 * |
|
1369 * Advanced Tactile feedback REQ417-47932 |
|
1370 * @return the tactile feedback type |
|
1371 */ |
|
1372 IMPORT_C TInt TactileFeedbackType(); |
|
1373 |
|
1374 private: |
|
1375 /** |
|
1376 * Tactile Feedback type |
|
1377 */ |
|
1378 TInt iTactileType; |
|
1379 }; |
|
1380 }; |
|
1381 //end of class CFepUiBaseCtrl |
|
1382 #include "peninputlayoutbasecontrol.inl" |
|
1383 #endif //C_CFEPUIBASECTRL_H |