55 }; |
55 }; |
56 |
56 |
57 // Own methods |
57 // Own methods |
58 public: |
58 public: |
59 /** |
59 /** |
60 * Get the visible rectangle of this control. |
|
61 * Window coordinates. |
|
62 * The clipping take in account the parent, but not the brother. |
|
63 * To take in account the brother use VisibleRegion() method. |
|
64 * @param aVisibleBounds If true return the visible rectangle of the control, |
|
65 * else return visible client rectangle of the control. |
|
66 */ |
|
67 TRect VisibleRect(TBool aVisibleBounds = EFalse) const; |
|
68 |
|
69 /** |
|
70 * Clips given rectangle to rectangle which can be fully visible in |
60 * Clips given rectangle to rectangle which can be fully visible in |
71 * its parent. Other controls in the same parent are not taken |
61 * its parent. Other controls in the same parent are not taken |
72 * into account. |
62 * into account. |
73 * @param aRect Rectangle to be clipped |
63 * @param aRect Rectangle to be clipped |
74 * @return Clipped rectangle |
64 * @return Clipped rectangle |
75 */ |
65 */ |
76 TRect ClipToVisibleRect(const TRect& aRect) const; |
66 TRect ClipToVisibleRect(const TRect& aRect) const; |
77 |
|
78 // Hurts the performance of non overlapping drawing when there are a lot |
|
79 // of control sibblings and does not really work for overlapping drawing |
|
80 #if 0 |
|
81 /** |
|
82 * Get the visible region of the Control. |
|
83 * Screen coordinates. |
|
84 * @param If true return the visible region of the control, |
|
85 * else return visible client region of the control. |
|
86 */ |
|
87 void VisibleRegion(RRegion& aRegion, TBool aVisibleBounds = EFalse) const; |
|
88 #endif |
|
89 |
67 |
90 /** |
68 /** |
91 * Provide the Skin background. |
69 * Provide the Skin background. |
92 * Should be called by the MopSupplyObject of all implementeded controls. |
70 * Should be called by the MopSupplyObject of all implementeded controls. |
93 */ |
71 */ |
395 }; |
373 }; |
396 IMPORT_C TBool IsLongTapAnimationCandidate(const TPointerEvent& aPointerEvent) const; |
374 IMPORT_C TBool IsLongTapAnimationCandidate(const TPointerEvent& aPointerEvent) const; |
397 IMPORT_C void DoControlSpecificFeedback(const TBool& aFirstTap, |
375 IMPORT_C void DoControlSpecificFeedback(const TBool& aFirstTap, |
398 const TBool& aTappedToChildRect, const TPointerEvent& aPointerEvent) const; |
376 const TBool& aTappedToChildRect, const TPointerEvent& aPointerEvent) const; |
399 IMPORT_C void PostMouseEventL(const TPointerEvent& aPointerEvent); |
377 IMPORT_C void PostMouseEventL(const TPointerEvent& aPointerEvent); |
|
378 IMPORT_C void EnableFocusHighlight(TBool aEnable); |
|
379 IMPORT_C TRect VisibleRect(TBool aVisibleBounds = EFalse) const; |
400 |
380 |
401 protected: |
381 protected: |
402 MSwtDisplay& iDisplay; |
382 MSwtDisplay& iDisplay; |
403 const TSwtPeer iPeer; // The Java peer object |
383 const TSwtPeer iPeer; // The Java peer object |
404 MSwtComposite* const iParent; // The parent control, not owned, may be NULL if we are a Shell |
384 MSwtComposite* const iParent; // The parent control, not owned, may be NULL if we are a Shell |
411 TInt iStackedSetRedrawFalseNb; // The number of setRedraw(true) must be equal to the number of setRedraw(false) to allow drawing |
391 TInt iStackedSetRedrawFalseNb; // The number of setRedraw(true) must be equal to the number of setRedraw(false) to allow drawing |
412 TBool iBackgrdDefaultUsed; |
392 TBool iBackgrdDefaultUsed; |
413 CAknsFrameBackgroundControlContext* iFocusFrame; // Frame context used to draw focus highlight background. |
393 CAknsFrameBackgroundControlContext* iFocusFrame; // Frame context used to draw focus highlight background. |
414 TBool iTraverse; // True when a keypress causes traversing |
394 TBool iTraverse; // True when a keypress causes traversing |
415 TPoint iPrevSwtPos; // Used by HandleSizeChanged and HandlePositionChanged only |
395 TPoint iPrevSwtPos; // Used by HandleSizeChanged and HandlePositionChanged only |
416 TSize iPrevSwtSize; // Used by HandleSizeChanged and HandlePositionChanged only |
|
417 TPoint iPrevCoePos; // Used by HandleSizeChanged and HandlePositionChanged only |
396 TPoint iPrevCoePos; // Used by HandleSizeChanged and HandlePositionChanged only |
418 TSize iPrevCoeSize; // Used by HandleSizeChanged and HandlePositionChanged only |
397 TSize iPrevCoeSize; // Used by HandleSizeChanged and HandlePositionChanged only |
419 |
398 |
420 // True if control changed its focus. |
399 // True if control changed its focus. |
421 // Currently used for advanced tactile feedback. |
400 // Currently used for advanced tactile feedback. |