idlehomescreen/xmluirendering/renderingplugins/xnclockfactory/inc/xnclockcontrol.h
--- a/idlehomescreen/xmluirendering/renderingplugins/xnclockfactory/inc/xnclockcontrol.h Wed Sep 01 12:32:46 2010 +0100
+++ b/idlehomescreen/xmluirendering/renderingplugins/xnclockfactory/inc/xnclockcontrol.h Tue Sep 14 20:58:58 2010 +0300
@@ -28,6 +28,7 @@
class CWindowGc;
class CXnClockAdapter;
class CXnClockFace;
+class CXnNodePluginIf;
// Class declaration
/**
@@ -44,17 +45,15 @@
*
* @since S60 5.1
*
- * @param aContainerWindow Container window for the clock component.
- *
+ * @param aAdapter Reference to clockadapter.
* @param aFormatFromLocale Boolean flag to indicate whether the clock
* format should be updated from the locale.
- *
- * @param aContextPaneClock Boolean flag that indicates whether the
- * clock is in the context pane.
+ * @param aFormat Boolean flag that indicates whether the
+ * clock is digital or analog.
*
* @return Newly constructed object.
*/
- static CXnClockControl* NewL( CXnClockAdapter* aAdapter,
+ static CXnClockControl* NewL( CXnClockAdapter& aAdapter,
const TBool aFormatFromLocale,
const TClockFormat aFormat );
@@ -91,9 +90,10 @@
* Draws the clock
*
* @param aGc Context where to draw
- * @param aRect Rect Clock rect
+ * @param aNode Node to draw
+ * @param aAmpm Possible am/pm text to draw
*/
- void Draw( CWindowGc& aGc, const TRect& aRect );
+ void Draw( CWindowGc& aGc, CXnNodePluginIf* aNode, CXnNodePluginIf* aAmpm );
/**
* Starts the clock timer.
@@ -106,6 +106,16 @@
* Used when the clock loses visibility.
*/
void StopTimer();
+
+ /**
+ * Checks if clock format has changed
+ */
+ void CheckClockFormatL();
+
+ /**
+ * Reset font and color
+ */
+ void ResetFont();
private: // New functions
@@ -123,7 +133,7 @@
/**
* C++ default constructor.
*/
- CXnClockControl( CXnClockAdapter* aAdapter,
+ CXnClockControl( CXnClockAdapter& aAdapter,
const TBool aFormatFromLocale,
const TClockFormat aFormat );
@@ -139,11 +149,13 @@
// Clock face, owned
CXnClockFace* iFace;
// Clock adapter, not owned
- CXnClockAdapter* iAdapter;
+ CXnClockAdapter& iAdapter;
// Clock format
- TClockFormat iClockFormat;
- // Flag indicating whetger format clock from locale
- TBool iFormatFromLocale;
+ TClockFormat iClockFormat;
+ // Time format
+ TTimeFormat iTimeFormat;
+ // Flag indicating whether format clock from locale
+ TBool iFormatFromLocale;
};
#endif // _XNCLOCKCONTROL_H