201033
authorhgs
Wed, 25 Aug 2010 14:02:13 +0530
changeset 63 a3cb48f6c889
parent 57 bb2d3e476f29
child 64 1881ad52dc45
201033
alarmui/alarmalertwidget/alarmalertplugin/data/xml/alarmalert_calendar_unlocked.docml
alarmui/alarmalertwidget/alarmalertplugin/data/xml/alarmalert_clock_unlocked.docml
alarmui/alarmalertwidget/alarmalertplugin/data/xml/alarmalert_todo_unlocked.docml
alarmui/alarmalertwidget/alarmalertplugin/inc/alarmalertwidget_p.h
alarmui/alarmalertwidget/alarmalertplugin/src/alarmalertwidget_p.cpp
calendarui/agendaeventviewer/bwins/agendaeventvieweru.def
calendarui/agendaeventviewer/eabi/agendaeventvieweru.def
calendarui/agendaeventviewer/inc/agendaeventview.h
calendarui/agendaeventviewer/inc/agendaeventviewer.h
calendarui/agendaeventviewer/inc/agendaeventviewer_p.h
calendarui/agendaeventviewer/src/agendaeventview.cpp
calendarui/agendaeventviewer/src/agendaeventviewer.cpp
calendarui/agendaeventviewer/src/agendaeventviewer_p.cpp
calendarui/caleneditor/data/caleneditor.qrc
calendarui/caleneditor/data/caleneditorcustomitem.css
calendarui/caleneditor/data/caleneditorlocationitem.docml
calendarui/caleneditor/src/caleneditorcustomitem.cpp
calendarui/caleneditor/src/caleneditorreminderfield.cpp
calendarui/caleneditor/src/caleneditorrepeatfield.cpp
calendarui/controller/data/xml/calendayview.docml
calendarui/controller/data/xml/calenmonthview.docml
calendarui/controller/inc/calenviewmanager.h
calendarui/controller/src/calencontroller.cpp
calendarui/controller/src/calendocloader.cpp
calendarui/controller/src/calenviewmanager.cpp
calendarui/inc/calencommon.h
calendarui/views/bwins/calenviewsu.def
calendarui/views/dayview/inc/calendaycommonheaders.h
calendarui/views/dayview/inc/calendaycontentscrollarea.h
calendarui/views/dayview/inc/calendaycontentwidget.h
calendarui/views/dayview/inc/calendaystatusstrip.h
calendarui/views/dayview/inc/calendayview.h
calendarui/views/dayview/resources/calendayitem.widgetml
calendarui/views/dayview/src/calendaycontainer.cpp
calendarui/views/dayview/src/calendaycontentscrollarea.cpp
calendarui/views/dayview/src/calendaycontentwidget.cpp
calendarui/views/dayview/src/calendayeventspane.cpp
calendarui/views/dayview/src/calendayhourelement.cpp
calendarui/views/dayview/src/calendayitem.cpp
calendarui/views/dayview/src/calendayitemview.cpp
calendarui/views/dayview/src/calendaymodelmanager.cpp
calendarui/views/dayview/src/calendaystatusstrip.cpp
calendarui/views/dayview/src/calendayutils.cpp
calendarui/views/dayview/src/calendayview.cpp
calendarui/views/dayview/tsrc/unittests/unittest_calendaystatusstrip/unittest_calendaystatusstrip.cpp
calendarui/views/dayview/tsrc/unittests/unittest_calendayview/calendayutils.h
calendarui/views/eabi/calenviewsu.def
calendarui/views/inc/calengriditemprototype.h
calendarui/views/inc/calenmonthgrid.h
calendarui/views/inc/calenmonthview.h
calendarui/views/inc/calenpreviewpane.h
calendarui/views/inc/calenthicklinesdrawer.h
calendarui/views/resources/calenresources.qrc
calendarui/views/resources/qgn_indi_cdr_meeting_layer0.svg
calendarui/views/resources/qtg_graf_cal_event_ind.svg
calendarui/views/resources/qtg_mono_exception.png
calendarui/views/src/calengriditemprototype.cpp
calendarui/views/src/calenmonthgrid.cpp
calendarui/views/src/calenmonthview.cpp
calendarui/views/src/calenpreviewpane.cpp
calendarui/views/src/calenthicklinesdrawer.cpp
calendarui/views/traces/calengriditemprototypeTraces.h
calendarui/views/traces/calenmonthgridTraces.h
calendarui/views/traces/calenmonthviewTraces.h
calendarui/views/traces/calenpreviewpaneTraces.h
calendarui/views/traces/calenthicklinesdrawerTraces.h
calendarui/views/traces/fixed_id.definitions
clock/clock.pro
clock/clockui/clockalarmeditor/src/clockalarmeditor.cpp
clock/clockui/clockplugins/datetimesettingsplugin/inc/datetimesettingsplugin.h
clock/clockui/clockplugins/datetimesettingsplugin/inc/datetimesettingsview.h
clock/clockui/clockplugins/datetimesettingsplugin/src/datetimesettingsplugin.cpp
clock/clockui/clockplugins/datetimesettingsplugin/src/datetimesettingsview.cpp
clock/clockui/clocksettingsview/bwins/clocksettingsviewu.def
clock/clockui/clocksettingsview/data/clocksettingsview.qrc
clock/clockui/clocksettingsview/data/style/settingscustomitem.css
clock/clockui/clocksettingsview/eabi/clocksettingsviewu.def
clock/clockui/clocksettingsview/inc/clockregionalsettingsview.h
clock/clockui/clocksettingsview/inc/clocksettingsview.h
clock/clockui/clocksettingsview/inc/settingscustomitem.h
clock/clockui/clocksettingsview/inc/settingsdatatypes.h
clock/clockui/clocksettingsview/src/clockregionalsettingsview.cpp
clock/clockui/clocksettingsview/src/clocksettingsview.cpp
clock/clockui/clocksettingsview/src/settingscustomitem.cpp
clock/clockui/clocksettingsview/traces/clocksettingsviewTraces.h
clock/clockui/clocksettingsview/traces/fixed_id.definitions
clock/clockui/clockviewmanager/src/clockviewmanager.cpp
clock/conf/CI_clockapp.confml
--- a/alarmui/alarmalertwidget/alarmalertplugin/data/xml/alarmalert_calendar_unlocked.docml	Mon Aug 09 18:30:52 2010 +0530
+++ b/alarmui/alarmalertwidget/alarmalertplugin/data/xml/alarmalert_calendar_unlocked.docml	Wed Aug 25 14:02:13 2010 +0530
@@ -7,6 +7,8 @@
         <string locid="txt_calendar_button_alarm_stop" name="text" value="Stop"/>
     </object>
     <widget name="dialog" type="HbDialog">
+        <ref object="snoozeAction" role="HbWidget:addAction"/>
+        <ref object="stopAction" role="HbWidget:addAction"/>
         <widget name="heading" role="HbDialog:headingWidget" type="HbLabel">
             <enums name="alignment" value="AlignLeft|AlignLeading"/>
             <string locid="txt_calendar_title_calendar_alarm" name="plainText" value="Calendar alarm"/>
@@ -14,100 +16,124 @@
         <widget name="container" role="HbDialog:contentWidget" type="HbWidget">
             <widget name="alarmTime" type="HbLabel">
                 <enums name="alignment" value="AlignVCenter|AlignHCenter"/>
-                <real name="z" value="1"/>
-                <sizehint height="var(hb-param-text-height-primary)" type="MINIMUM"/>
-                <string name="plainText" value="9:00 am"/>
+                <sizepolicy horizontalPolicy="Preferred" horizontalStretch="0" verticalPolicy="Preferred" verticalStretch="0"/>
+                <sizehint height="var(hb-param-text-height-primary)" type="PREFERRED" width="24un"/>
+                <string name="plainText" value="time"/>
             </widget>
             <widget name="alarmDate" type="HbLabel">
-                <enums name="alignment" value="AlignVCenter|AlignHCenter"/>
-                <real name="z" value="2"/>
-                <sizehint height="var(hb-param-text-height-secondary)" type="PREFERRED"/>
-                <string name="plainText" value="01/01/2010"/>
+                <real name="z" value="1"/>
+                <string name="plainText" value="date"/>
             </widget>
             <widget name="alarmDescription" type="HbLabel">
-                <enums name="textWrapping" value="TextWordWrap"/>
-                <enums name="alignment" value="AlignVCenter|AlignHCenter"/>
-                <real name="z" value="3"/>
-                <sizehint height="8un" type="PREFERRED"/>
-                <sizehint height="8un" type="MINIMUM"/>
-                <sizehint height="8un" type="MAXIMUM"/>
-                <string name="textFormat" value="PlainText"/>
+                <real name="z" value="2"/>
+                <sizehint height="var(hb-param-text-height-primary)" type="PREFERRED"/>
+                <string name="plainText" value="description"/>
             </widget>
             <widget name="alarmLocation" type="HbLabel">
-                <enums name="alignment" value="AlignVCenter|AlignHCenter"/>
-                <real name="z" value="4"/>
+                <real name="z" value="3"/>
                 <sizehint height="var(hb-param-text-height-secondary)" type="PREFERRED"/>
+                <string name="plainText" value="location"/>
             </widget>
             <widget name="alarmIcon" type="HbLabel">
                 <enums name="alignment" value="AlignVCenter|AlignHCenter"/>
                 <icon iconName="qtg_large_calendar_alarm" name="icon"/>
-                <real name="z" value="5"/>
-                <sizehint height="15un" type="PREFERRED" width="15un"/>
-            </widget>
-            <widget name="nonTimedAlarmDate" type="HbLabel">
-                <enums name="alignment" value="AlignVCenter|AlignHCenter"/>
-                <real name="z" value="1"/>
-                <sizehint height="var(hb-param-text-height-primary)" type="MINIMUM"/>
-                <string name="plainText" value="01/01/2010"/>
+                <real name="z" value="4"/>
+                <sizepolicy horizontalPolicy="Fixed" horizontalStretch="0" verticalPolicy="Fixed" verticalStretch="0"/>
+                <sizehint height="15un" type="FIXED" width="15un"/>
             </widget>
             <layout type="anchor">
-                <anchoritem dst="alarmTime" dstEdge="LEFT" spacing="var(hb-param-margin-gene-popup)" src="" srcEdge="LEFT"/>
-                <anchoritem dst="alarmTime" dstEdge="TOP" spacing="var(hb-param-margin-gene-popup)" src="" srcEdge="TOP"/>
-                <anchoritem dst="alarmTime" dstEdge="RIGHT" spacing="-var(hb-param-margin-gene-popup)" src="" srcEdge="RIGHT"/>
-                <anchoritem dst="alarmDate" dstEdge="LEFT" spacing="var(hb-param-margin-gene-popup)" src="" srcEdge="LEFT"/>
-                <anchoritem dst="alarmDate" dstEdge="TOP" spacing="var(hb-param-margin-gene-popup)" src="alarmTime" srcEdge="BOTTOM"/>
-                <anchoritem dst="alarmDate" dstEdge="RIGHT" spacing="-var(hb-param-margin-gene-popup)" src="" srcEdge="RIGHT"/>
-                <anchoritem dst="alarmDescription" dstEdge="LEFT" spacing="var(hb-param-margin-gene-popup)" src="" srcEdge="LEFT"/>
-                <anchoritem dst="alarmDescription" dstEdge="TOP" spacing="var(hb-param-margin-gene-popup)" src="alarmDate" srcEdge="BOTTOM"/>
-                <anchoritem dst="alarmDescription" dstEdge="RIGHT" spacing="-var(hb-param-margin-gene-popup)" src="" srcEdge="RIGHT"/>
-                <anchoritem dst="alarmLocation" dstEdge="LEFT" spacing="var(hb-param-margin-gene-popup)" src="" srcEdge="LEFT"/>
-                <anchoritem dst="alarmLocation" dstEdge="TOP" spacing="var(hb-param-margin-gene-popup)" src="alarmDescription" srcEdge="BOTTOM"/>
-                <anchoritem dst="alarmLocation" dstEdge="RIGHT" spacing="-var(hb-param-margin-gene-popup)" src="" srcEdge="RIGHT"/>
-                <anchoritem dst="alarmIcon" dstEdge="LEFT" spacing="17.5un" src="" srcEdge="LEFT"/>
-                <anchoritem dst="alarmIcon" dstEdge="TOP" spacing="var(hb-param-margin-gene-popup)" src="alarmLocation" srcEdge="BOTTOM"/>
-                <anchoritem dst="alarmIcon" dstEdge="BOTTOM" spacing="-var(hb-param-margin-gene-popup)" src="" srcEdge="BOTTOM"/>
+                <anchoritem dst="alarmTime" dstEdge="LEFT" spacing="1.34328un" src="" srcEdge="LEFT"/>
+                <anchoritem dst="alarmTime" dstEdge="TOP" spacing="1.34328un" src="" srcEdge="TOP"/>
+                <anchoritem dst="alarmDate" dstEdge="RIGHT" spacing="-21.37314un" src="" srcEdge="RIGHT"/>
+                <anchoritem dst="alarmDate" dstEdge="BOTTOM" spacing="-3.8806un" src="" srcEdge="BOTTOM"/>
+                <anchoritem dst="alarmDescription" dstEdge="LEFT" spacing="5.8209un" src="" srcEdge="LEFT"/>
+                <anchoritem dst="alarmDescription" dstEdge="BOTTOM" spacing="-3.13433un" src="" srcEdge="BOTTOM"/>
+                <anchoritem dst="alarmLocation" dstEdge="TOP" spacing="3.43284un" src="" srcEdge="TOP"/>
+                <anchoritem dst="alarmLocation" dstEdge="RIGHT" spacing="-8.83582un" src="" srcEdge="RIGHT"/>
+                <anchoritem dst="alarmIcon" dstEdge="RIGHT" spacing="-3.91045un" src="" srcEdge="RIGHT"/>
+                <anchoritem dst="alarmIcon" dstEdge="BOTTOM" spacing="-3.43284un" src="" srcEdge="BOTTOM"/>
+            </layout>
+        </widget>
+    </widget>
+    <section name="nonTimedAlarm">
+        <widget name="container" role="HbDialog:contentWidget" type="HbWidget">
+            <layout type="anchor">
+                <anchoritem dst="alarmDate" dstEdge="LEFT" spacing="expr(var(hb-param-margin-gene-popup) )" src="" srcEdge="LEFT"/>
+                <anchoritem dst="alarmDate" dstEdge="TOP" spacing="expr(var(hb-param-margin-gene-popup) )" src="" srcEdge="TOP"/>
+                <anchoritem dst="alarmDate" dstEdge="RIGHT" spacing="expr(-var(hb-param-margin-gene-popup) )" src="" srcEdge="RIGHT"/>
+                <anchoritem dst="alarmDescription" dstEdge="LEFT" spacing="expr(var(hb-param-margin-gene-popup) )" src="" srcEdge="LEFT"/>
+                <anchoritem dst="alarmDescription" dstEdge="TOP" spacing="expr(var(hb-param-margin-gene-popup) )" src="alarmDate" srcEdge="BOTTOM"/>
+                <anchoritem dst="alarmDescription" dstEdge="RIGHT" spacing="expr(-var(hb-param-margin-gene-popup) )" src="" srcEdge="RIGHT"/>
+                <anchoritem dst="alarmLocation" dstEdge="LEFT" spacing="expr(var(hb-param-margin-gene-popup) )" src="" srcEdge="LEFT"/>
+                <anchoritem dst="alarmLocation" dstEdge="TOP" spacing="expr(var(hb-param-margin-gene-popup) )" src="alarmDescription" srcEdge="BOTTOM"/>
+                <anchoritem dst="alarmLocation" dstEdge="RIGHT" spacing="expr(-var(hb-param-margin-gene-popup) )" src="" srcEdge="RIGHT"/>
+                <anchoritem dst="alarmIcon" dstEdge="TOP" spacing="expr(var(hb-param-margin-gene-popup) )" src="alarmLocation" srcEdge="BOTTOM"/>
+                <anchoritem dst="alarmIcon" dstEdge="BOTTOM" spacing="expr(-var(hb-param-margin-gene-popup) )" src="" srcEdge="BOTTOM"/>
+                <anchoritem dst="alarmIcon" dstEdge="CENTERH" spacing="0un" src="" srcEdge="CENTERH"/>
             </layout>
         </widget>
-        <ref object="snoozeAction" role="HbWidget:addAction"/>
-        <ref object="stopAction" role="HbWidget:addAction"/>
-    </widget>
-    <section name="calendarTimed"/>
-    <section name="nonTimedAlarm">
-        <widget name="heading" role="HbDialog:headingWidget" type="HbLabel">
-            <string locid="txt_calendar_title_calendar_alarm" name="plainText" value="Calendar alarm"/>
+        <widget name="alarmIcon" type="HbLabel">
+            <icon iconName="qtg_large_calendar_alarm" name="icon"/>
+            <sizepolicy horizontalPolicy="Preferred" horizontalStretch="0" verticalPolicy="Preferred" verticalStretch="0"/>
+        </widget>
+        <widget name="alarmLocation" type="HbLabel">
+            <enums name="alignment" value="AlignVCenter|AlignHCenter"/>
+        </widget>
+        <widget name="alarmDate" type="HbLabel">
+            <enums name="alignment" value="AlignVCenter|AlignHCenter"/>
+            <sizehint height="var(hb-param-text-height-primary)" type="PREFERRED"/>
         </widget>
-        <widget name="nonTimedAlarmDate" type="HbLabel">
+        <widget name="alarmTime" type="HbLabel">
+            <bool name="visible" value="FALSE"/>
+        </widget>
+        <widget name="alarmDescription" type="HbLabel">
+            <enums name="textWrapping" value="TextWordWrap"/>
             <enums name="alignment" value="AlignVCenter|AlignHCenter"/>
-            <real name="z" value="1"/>
-            <sizehint height="var(hb-param-text-height-primary)" type="MINIMUM"/>
-            <string name="plainText" value="01/01/2010"/>
+            <sizepolicy horizontalPolicy="Preferred" horizontalStretch="0" verticalPolicy="Maximum" verticalStretch="0"/>
+            <sizehint height="expr(3 * var(hb-param-text-height-primary))" type="PREFERRED"/>
         </widget>
+    </section>
+    <section name="calendarTimed">
         <widget name="container" role="HbDialog:contentWidget" type="HbWidget">
             <layout type="anchor">
-                <anchoritem dst="alarmTime" dstEdge="LEFT" spacing="var(hb-param-margin-gene-popup)" src="" srcEdge="LEFT"/>
-                <anchoritem dst="alarmTime" dstEdge="TOP" spacing="var(hb-param-margin-gene-popup)" src="" srcEdge="TOP"/>
-                <anchoritem dst="alarmTime" dstEdge="RIGHT" spacing="-var(hb-param-margin-gene-popup)" src="" srcEdge="RIGHT"/>
-                <anchoritem dst="alarmDate" dstEdge="LEFT" spacing="var(hb-param-margin-gene-popup)" src="" srcEdge="LEFT"/>
-                <anchoritem dst="alarmDate" dstEdge="TOP" spacing="var(hb-param-margin-gene-popup)" src="alarmTime" srcEdge="BOTTOM"/>
-                <anchoritem dst="alarmDate" dstEdge="RIGHT" spacing="-var(hb-param-margin-gene-popup)" src="" srcEdge="RIGHT"/>
-                <anchoritem dst="alarmDescription" dstEdge="LEFT" spacing="var(hb-param-margin-gene-popup)" src="" srcEdge="LEFT"/>
-                <anchoritem dst="alarmDescription" dstEdge="TOP" spacing="var(hb-param-margin-gene-popup)" src="nonTimedAlarmDate" srcEdge="BOTTOM"/>
-                <anchoritem dst="alarmDescription" dstEdge="RIGHT" spacing="-var(hb-param-margin-gene-popup)" src="" srcEdge="RIGHT"/>
-                <anchoritem dst="alarmLocation" dstEdge="LEFT" spacing="var(hb-param-margin-gene-popup)" src="" srcEdge="LEFT"/>
-                <anchoritem dst="alarmLocation" dstEdge="TOP" spacing="var(hb-param-margin-gene-popup)" src="alarmDescription" srcEdge="BOTTOM"/>
-                <anchoritem dst="alarmLocation" dstEdge="RIGHT" spacing="-var(hb-param-margin-gene-popup)" src="" srcEdge="RIGHT"/>
-                <anchoritem dst="nonTimedAlarmDate" dstEdge="LEFT" spacing="expr(var(hb-param-margin-gene-popup) )" src="" srcEdge="LEFT"/>
-                <anchoritem dst="nonTimedAlarmDate" dstEdge="TOP" spacing="expr(var(hb-param-margin-gene-popup) )" src="" srcEdge="TOP"/>
-                <anchoritem dst="nonTimedAlarmDate" dstEdge="RIGHT" spacing="expr(-var(hb-param-margin-gene-popup) )" src="" srcEdge="RIGHT"/>
-                <anchoritem dst="alarmIcon" dstEdge="LEFT" spacing="17.5un" src="" srcEdge="LEFT"/>
-                <anchoritem dst="alarmIcon" dstEdge="TOP" spacing="var(hb-param-margin-gene-popup)" src="alarmLocation" srcEdge="BOTTOM"/>
+                <anchoritem dst="alarmTime" dstEdge="LEFT" spacing="expr(var(hb-param-margin-gene-popup) )" src="" srcEdge="LEFT"/>
+                <anchoritem dst="alarmTime" dstEdge="TOP" spacing="expr(var(hb-param-margin-gene-popup) )" src="" srcEdge="TOP"/>
+                <anchoritem dst="alarmTime" dstEdge="RIGHT" spacing="expr(-var(hb-param-margin-gene-popup) )" src="" srcEdge="RIGHT"/>
+                <anchoritem dst="alarmDate" dstEdge="LEFT" spacing="expr(var(hb-param-margin-gene-popup) )" src="" srcEdge="LEFT"/>
+                <anchoritem dst="alarmDate" dstEdge="TOP" spacing="expr(var(hb-param-margin-gene-popup) )" src="alarmTime" srcEdge="BOTTOM"/>
+                <anchoritem dst="alarmDate" dstEdge="RIGHT" spacing="expr(-var(hb-param-margin-gene-popup) )" src="" srcEdge="RIGHT"/>
+                <anchoritem dst="alarmDescription" dstEdge="LEFT" spacing="expr(var(hb-param-margin-gene-popup) )" src="" srcEdge="LEFT"/>
+                <anchoritem dst="alarmDescription" dstEdge="TOP" spacing="expr(var(hb-param-margin-gene-popup) )" src="alarmDate" srcEdge="BOTTOM"/>
+                <anchoritem dst="alarmDescription" dstEdge="RIGHT" spacing="expr(-var(hb-param-margin-gene-popup) )" src="" srcEdge="RIGHT"/>
+                <anchoritem dst="alarmLocation" dstEdge="LEFT" spacing="expr(var(hb-param-margin-gene-popup) )" src="" srcEdge="LEFT"/>
+                <anchoritem dst="alarmLocation" dstEdge="TOP" spacing="expr(var(hb-param-margin-gene-popup) )" src="alarmDescription" srcEdge="BOTTOM"/>
+                <anchoritem dst="alarmLocation" dstEdge="RIGHT" spacing="expr(-var(hb-param-margin-gene-popup) )" src="" srcEdge="RIGHT"/>
+                <anchoritem dst="alarmIcon" dstEdge="TOP" spacing="expr(var(hb-param-margin-gene-popup) )" src="alarmLocation" srcEdge="BOTTOM"/>
                 <anchoritem dst="alarmIcon" dstEdge="BOTTOM" spacing="expr(-var(hb-param-margin-gene-popup) )" src="" srcEdge="BOTTOM"/>
+                <anchoritem dst="alarmIcon" dstEdge="CENTERH" spacing="0un" src="" srcEdge="CENTERH"/>
             </layout>
         </widget>
+        <widget name="alarmIcon" type="HbLabel">
+            <sizepolicy horizontalPolicy="Preferred" horizontalStretch="0" verticalPolicy="Preferred" verticalStretch="0"/>
+            <icon iconName="qtg_large_calendar_alarm" name="icon"/>
+        </widget>
+        <widget name="alarmLocation" type="HbLabel">
+            <enums name="alignment" value="AlignVCenter|AlignHCenter"/>
+        </widget>
+        <widget name="alarmDate" type="HbLabel">
+            <enums name="alignment" value="AlignVCenter|AlignHCenter"/>
+            <sizehint height="var(hb-param-text-height-secondary)" type="PREFERRED"/>
+        </widget>
+        <widget name="alarmDescription" type="HbLabel">
+            <enums name="textWrapping" value="TextWordWrap"/>
+            <enums name="alignment" value="AlignVCenter|AlignHCenter"/>
+            <sizehint height="expr(2 * var(hb-param-text-height-primary))" type="PREFERRED"/>
+            <sizepolicy horizontalPolicy="Preferred" horizontalStretch="0" verticalPolicy="Maximum" verticalStretch="0"/>
+        </widget>
     </section>
-    <metadata activeUIState="nonTimedAlarm" display="NHD portrait" unit="un">
+    <metadata activeUIState="calendarTimed" display="NHD-3.2-inch_portrait" unit="un">
         <uistate name="Common ui state" sections="#common"/>
+        <uistate name="nonTimedAlarm" sections="#common nonTimedAlarm"/>
         <uistate name="calendarTimed" sections="#common calendarTimed"/>
-        <uistate name="nonTimedAlarm" sections="#common nonTimedAlarm"/>
     </metadata>
 </hbdocument>
--- a/alarmui/alarmalertwidget/alarmalertplugin/data/xml/alarmalert_clock_unlocked.docml	Mon Aug 09 18:30:52 2010 +0530
+++ b/alarmui/alarmalertwidget/alarmalertplugin/data/xml/alarmalert_clock_unlocked.docml	Wed Aug 25 14:02:13 2010 +0530
@@ -16,14 +16,15 @@
                 <enums name="alignment" value="AlignVCenter|AlignHCenter"/>
                 <real name="z" value="1"/>
                 <sizehint height="10un" type="MINIMUM"/>
+                <string name="plainText" value="9:00 am"/>
                 <fontspec name="fontSpec" role="Primary" textheight="9.8un"/>
-                <string name="plainText" value="9:00 am"/>
+                <sizehint height="10un" type="PREFERRED"/>
             </widget>
             <widget name="alarmDescription" type="HbLabel">
                 <enums name="textWrapping" value="TextWordWrap"/>
                 <enums name="alignment" value="AlignVCenter|AlignHCenter"/>
                 <real name="z" value="3"/>
-                <sizehint height="7un" type="PREFERRED"/>
+                <sizehint height="expr(2 * var(hb-param-text-height-secondary) )" type="PREFERRED"/>
                 <sizehint height="7un" type="MINIMUM"/>
                 <sizehint height="7un" type="MAXIMUM"/>
                 <string name="textFormat" value="PlainText"/>
@@ -33,6 +34,7 @@
                 <icon iconName="qtg_large_bell" name="icon"/>
                 <real name="z" value="5"/>
                 <sizehint height="15un" type="PREFERRED" width="15un"/>
+                <sizepolicy horizontalPolicy="Preferred" horizontalStretch="0" verticalPolicy="Preferred" verticalStretch="0"/>
             </widget>
             <layout type="anchor">
                 <anchoritem dst="alarmTime" dstEdge="LEFT" spacing="var(hb-param-margin-gene-popup)" src="" srcEdge="LEFT"/>
@@ -41,15 +43,15 @@
                 <anchoritem dst="alarmDescription" dstEdge="LEFT" spacing="var(hb-param-margin-gene-popup)" src="" srcEdge="LEFT"/>
                 <anchoritem dst="alarmDescription" dstEdge="TOP" spacing="var(hb-param-margin-gene-popup)" src="alarmTime" srcEdge="BOTTOM"/>
                 <anchoritem dst="alarmDescription" dstEdge="RIGHT" spacing="-var(hb-param-margin-gene-popup)" src="" srcEdge="RIGHT"/>
-                <anchoritem dst="alarmIcon" dstEdge="LEFT" spacing="17.5un" src="" srcEdge="LEFT"/>
                 <anchoritem dst="alarmIcon" dstEdge="TOP" spacing="var(hb-param-margin-gene-popup)" src="alarmDescription" srcEdge="BOTTOM"/>
                 <anchoritem dst="alarmIcon" dstEdge="BOTTOM" spacing="-var(hb-param-margin-gene-popup)" src="" srcEdge="BOTTOM"/>
+                <anchoritem dst="alarmIcon" dstEdge="CENTERH" spacing="0un" src="" srcEdge="CENTERH"/>
             </layout>
         </widget>
         <ref object="snoozeAction" role="HbWidget:addAction"/>
         <ref object="stopAction" role="HbWidget:addAction"/>
     </widget>
-    <metadata activeUIState="Common ui state" display="NHD portrait" unit="un">
+    <metadata activeUIState="Common ui state" display="NHD-3.2-inch_portrait" unit="un">
         <uistate name="Common ui state" sections="#common"/>
     </metadata>
 </hbdocument>
--- a/alarmui/alarmalertwidget/alarmalertplugin/data/xml/alarmalert_todo_unlocked.docml	Mon Aug 09 18:30:52 2010 +0530
+++ b/alarmui/alarmalertwidget/alarmalertplugin/data/xml/alarmalert_todo_unlocked.docml	Wed Aug 25 14:02:13 2010 +0530
@@ -24,14 +24,16 @@
                 <real name="z" value="3"/>
                 <sizehint height="16un" type="PREFERRED"/>
                 <sizehint height="16un" type="MINIMUM"/>
-                <sizehint height="16un" type="MAXIMUM"/>
+                <sizehint height="expr(4 * var(hb-param-text-height-primary) )" type="MAXIMUM"/>
                 <string name="textFormat" value="PlainText"/>
+                <sizepolicy horizontalPolicy="Preferred" horizontalStretch="0" verticalPolicy="Maximum" verticalStretch="0"/>
             </widget>
             <widget name="alarmIcon" type="HbLabel">
                 <enums name="alignment" value="AlignVCenter|AlignHCenter"/>
                 <icon iconName="qtg_large_todo_alarm" name="icon"/>
                 <real name="z" value="5"/>
                 <sizehint height="15un" type="PREFERRED" width="15un"/>
+                <sizepolicy horizontalPolicy="Preferred" horizontalStretch="0" verticalPolicy="Preferred" verticalStretch="0"/>
             </widget>
             <layout type="anchor">
                 <anchoritem dst="alarmDate" dstEdge="LEFT" spacing="var(hb-param-margin-gene-popup)" src="" srcEdge="LEFT"/>
@@ -40,15 +42,15 @@
                 <anchoritem dst="alarmDescription" dstEdge="LEFT" spacing="var(hb-param-margin-gene-popup)" src="" srcEdge="LEFT"/>
                 <anchoritem dst="alarmDescription" dstEdge="TOP" spacing="var(hb-param-margin-gene-popup)" src="alarmDate" srcEdge="BOTTOM"/>
                 <anchoritem dst="alarmDescription" dstEdge="RIGHT" spacing="-var(hb-param-margin-gene-popup)" src="" srcEdge="RIGHT"/>
-                <anchoritem dst="alarmIcon" dstEdge="LEFT" spacing="17.5un" src="" srcEdge="LEFT"/>
                 <anchoritem dst="alarmIcon" dstEdge="TOP" spacing="var(hb-param-margin-gene-popup)" src="alarmDescription" srcEdge="BOTTOM"/>
                 <anchoritem dst="alarmIcon" dstEdge="BOTTOM" spacing="-var(hb-param-margin-gene-popup)" src="" srcEdge="BOTTOM"/>
+                <anchoritem dst="alarmIcon" dstEdge="CENTERH" spacing="0un" src="" srcEdge="CENTERH"/>
             </layout>
         </widget>
         <ref object="snoozeAction" role="HbWidget:addAction"/>
         <ref object="stopAction" role="HbWidget:addAction"/>
     </widget>
-    <metadata activeUIState="Common ui state" display="NHD portrait" unit="un">
+    <metadata activeUIState="Common ui state" display="NHD-3.2-inch_portrait" unit="un">
         <uistate name="Common ui state" sections="#common"/>
     </metadata>
 </hbdocument>
--- a/alarmui/alarmalertwidget/alarmalertplugin/inc/alarmalertwidget_p.h	Mon Aug 09 18:30:52 2010 +0530
+++ b/alarmui/alarmalertwidget/alarmalertplugin/inc/alarmalertwidget_p.h	Wed Aug 25 14:02:13 2010 +0530
@@ -18,6 +18,7 @@
 
 // System includes
 #include <QDateTime>
+#include <QPointer>
 #include <hbdialog.h>
 #include <hbdevicedialoginterface.h>
 #include <hbeffect.h>
@@ -215,19 +216,19 @@
      * @var mAlarmDescription
      * @brief Points to the alarm description label
      */
-    HbLabel *mAlarmDescription;
+    QPointer<HbLabel> mAlarmDescription;
     
     /**
     * @var mAlarmDateTime
     * @brief Points to the alarm expiry time label
     */
-    HbLabel *mAlarmDateTime;
+    QPointer<HbLabel> mAlarmDateTime;
     
     /**
      * @var mAlarmIcon
      * @brief Points to the alarm icon label
      */
-    HbLabel *mAlarmIcon;
+    QPointer<HbLabel> mAlarmIcon;
     
     /**
      * @var mMainWindow
--- a/alarmui/alarmalertwidget/alarmalertplugin/src/alarmalertwidget_p.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/alarmui/alarmalertwidget/alarmalertplugin/src/alarmalertwidget_p.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -417,12 +417,6 @@
 			qFatal("Unable to find the alarmDate label");
 		}
 		alarmDate->setPlainText(mAlarmDate);
-		HbLabel *alarmDateNonTimed = qobject_cast<HbLabel*> (
-				mAlertDocLoader->findWidget("nonTimedAlarmDate"));
-		if (!alarmDateNonTimed) {
-			qFatal("Unable to find the nonTimedAlarmDate label");
-		}
-		alarmDateNonTimed->hide();
 	}else {
 		mAlertDocLoader->load(
 				alarmNormalUICalendarDocml, "nonTimedAlarm",&success);
@@ -440,13 +434,7 @@
 		if (!alarmDate) {
 			qFatal("Unable to find the alarmDate label");
 		}
-		alarmDate->hide();
-		HbLabel *alarmDateNonTimed = qobject_cast<HbLabel*> (
-				mAlertDocLoader->findWidget("nonTimedAlarmDate"));
-		if (!alarmDateNonTimed) {
-			qFatal("Unable to find the alarmDateNonTimed label");
-		}
-		alarmDateNonTimed->setPlainText(mAlarmDate);
+		alarmDate->setPlainText(mAlarmDate);
 	}
 
 	QGraphicsWidget *headingWidget = mAlertDocLoader->findWidget("heading");
--- a/calendarui/agendaeventviewer/bwins/agendaeventvieweru.def	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/agendaeventviewer/bwins/agendaeventvieweru.def	Wed Aug 25 14:02:13 2010 +0530
@@ -1,8 +1,10 @@
 EXPORTS
-	?view@AgendaEventViewer@@QAEXVAgendaEntry@@W4Actions@1@@Z @ 1 NONAME ; void AgendaEventViewer::view(class AgendaEntry, enum AgendaEventViewer::Actions)
-	?view@AgendaEventViewer@@QAEXABVQFile@@W4Actions@1@@Z @ 2 NONAME ; void AgendaEventViewer::view(class QFile const &, enum AgendaEventViewer::Actions)
-	??1AgendaEventViewer@@UAE@XZ @ 3 NONAME ; AgendaEventViewer::~AgendaEventViewer(void)
-	??0AgendaEventViewer@@QAE@PAVAgendaUtil@@PAVQObject@@@Z @ 4 NONAME ; AgendaEventViewer::AgendaEventViewer(class AgendaUtil *, class QObject *)
-	?view@AgendaEventViewer@@QAEXKW4Actions@1@@Z @ 5 NONAME ; void AgendaEventViewer::view(unsigned long, enum AgendaEventViewer::Actions)
-	??0AgendaEventViewer@@QAE@PAVQObject@@@Z @ 6 NONAME ; AgendaEventViewer::AgendaEventViewer(class QObject *)
+	?view@AgendaEventViewer@@QAEXABVQFile@@W4Actions@1@@Z @ 1 NONAME ; void AgendaEventViewer::view(class QFile const &, enum AgendaEventViewer::Actions)
+	??1AgendaEventViewer@@UAE@XZ @ 2 NONAME ; AgendaEventViewer::~AgendaEventViewer(void)
+	?saveAndCloseEditor@AgendaEventViewer@@QAEXXZ @ 3 NONAME ; void AgendaEventViewer::saveAndCloseEditor(void)
+	?view@AgendaEventViewer@@QAEXVAgendaEntry@@W4Actions@1@@Z @ 4 NONAME ; void AgendaEventViewer::view(class AgendaEntry, enum AgendaEventViewer::Actions)
+	??0AgendaEventViewer@@QAE@PAVAgendaUtil@@PAVQObject@@@Z @ 5 NONAME ; AgendaEventViewer::AgendaEventViewer(class AgendaUtil *, class QObject *)
+	?closeAgendaEventView@AgendaEventViewer@@QAEXXZ @ 6 NONAME ; void AgendaEventViewer::closeAgendaEventView(void)
+	?view@AgendaEventViewer@@QAEXKW4Actions@1@@Z @ 7 NONAME ; void AgendaEventViewer::view(unsigned long, enum AgendaEventViewer::Actions)
+	??0AgendaEventViewer@@QAE@PAVQObject@@@Z @ 8 NONAME ; AgendaEventViewer::AgendaEventViewer(class QObject *)
 
--- a/calendarui/agendaeventviewer/eabi/agendaeventvieweru.def	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/agendaeventviewer/eabi/agendaeventvieweru.def	Wed Aug 25 14:02:13 2010 +0530
@@ -1,12 +1,14 @@
 EXPORTS
-	_ZN17AgendaEventViewer4viewE11AgendaEntryNS_7ActionsE @ 1 NONAME
-	_ZN17AgendaEventViewer4viewERK5QFileNS_7ActionsE @ 2 NONAME
-	_ZN17AgendaEventViewer4viewEmNS_7ActionsE @ 3 NONAME
-	_ZN17AgendaEventViewerC1EP10AgendaUtilP7QObject @ 4 NONAME
-	_ZN17AgendaEventViewerC1EP7QObject @ 5 NONAME
-	_ZN17AgendaEventViewerC2EP10AgendaUtilP7QObject @ 6 NONAME
-	_ZN17AgendaEventViewerC2EP7QObject @ 7 NONAME
-	_ZN17AgendaEventViewerD0Ev @ 8 NONAME
-	_ZN17AgendaEventViewerD1Ev @ 9 NONAME
-	_ZN17AgendaEventViewerD2Ev @ 10 NONAME
+	_ZN17AgendaEventViewer18saveAndCloseEditorEv @ 1 NONAME
+	_ZN17AgendaEventViewer20closeAgendaEventViewEv @ 2 NONAME
+	_ZN17AgendaEventViewer4viewE11AgendaEntryNS_7ActionsE @ 3 NONAME
+	_ZN17AgendaEventViewer4viewERK5QFileNS_7ActionsE @ 4 NONAME
+	_ZN17AgendaEventViewer4viewEmNS_7ActionsE @ 5 NONAME
+	_ZN17AgendaEventViewerC1EP10AgendaUtilP7QObject @ 6 NONAME
+	_ZN17AgendaEventViewerC1EP7QObject @ 7 NONAME
+	_ZN17AgendaEventViewerC2EP10AgendaUtilP7QObject @ 8 NONAME
+	_ZN17AgendaEventViewerC2EP7QObject @ 9 NONAME
+	_ZN17AgendaEventViewerD0Ev @ 10 NONAME
+	_ZN17AgendaEventViewerD1Ev @ 11 NONAME
+	_ZN17AgendaEventViewerD2Ev @ 12 NONAME
 
--- a/calendarui/agendaeventviewer/inc/agendaeventview.h	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/agendaeventviewer/inc/agendaeventview.h	Wed Aug 25 14:02:13 2010 +0530
@@ -50,7 +50,19 @@
 	AgendaEventView(
 			AgendaEventViewerPrivate *owner, QObject *parent=0);
 	virtual ~AgendaEventView();
-
+public:
+	
+	/*
+	 * forcefully closing the editor.
+	 * should be call if view is open,
+	 */
+	void saveAndCloseEditor();
+    
+	/*
+     * forcefully closing the view.
+     * should be call if view is open,
+     */
+    void closeAgendaEventView();
 private:
 	void execute(AgendaEntry entry, AgendaEventViewer::Actions action);
 	void addViewerData();
@@ -125,6 +137,7 @@
 	QTimer *mProgressTimer;
 	int mProgressIconCount;  
 	bool mMaptileStatusReceived;
+	bool mCalenEditorClosed ;
 	int mMaptileStatus; 
 	bool mNotesPluginLoaded;
 
--- a/calendarui/agendaeventviewer/inc/agendaeventviewer.h	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/agendaeventviewer/inc/agendaeventviewer.h	Wed Aug 25 14:02:13 2010 +0530
@@ -63,6 +63,10 @@
 	AGENDAEVENTVIEWER_EXPORT void view(AgendaEntry entry, 
 	                                   Actions action = ActionNothing);
 
+	AGENDAEVENTVIEWER_EXPORT void saveAndCloseEditor();
+	
+	AGENDAEVENTVIEWER_EXPORT void closeAgendaEventView();
+
 signals:
 	void viewingCompleted(const QDate date = QDate());
 	void editingStarted();
--- a/calendarui/agendaeventviewer/inc/agendaeventviewer_p.h	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/agendaeventviewer/inc/agendaeventviewer_p.h	Wed Aug 25 14:02:13 2010 +0530
@@ -43,6 +43,18 @@
 	void view(const ulong id, AgendaEventViewer::Actions action);
 	void view(const QFile &fileHandle, AgendaEventViewer::Actions action);
 	void view(AgendaEntry entry, AgendaEventViewer::Actions action);
+	
+    /**
+     * close the editor and save the entry
+     * should be call if editor is open
+     */
+	void saveAndCloseEditor();
+    
+	/**
+     * close agenda event view
+     * should be call if agenda eevent view is open
+     */
+	void closeAgendaEventView();
 
 private slots:
 	void viewingCompleted(const QDate date);
--- a/calendarui/agendaeventviewer/src/agendaeventview.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/agendaeventviewer/src/agendaeventview.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -94,7 +94,8 @@
 		mProgressIconCount(0),
 		mMaptileStatusReceived(false),
 		mMaptileStatus(-1),
-		mNotesPluginLoaded(false)
+		mNotesPluginLoaded(false),
+		mCalenEditorClosed(true)		        
 {
 	OstTraceFunctionEntry0( AGENDAEVENTVIEW_AGENDAEVENTVIEW_ENTRY );
 	mTranslator->loadCommon();
@@ -1110,7 +1111,7 @@
 		connect(mCalenEditor, SIGNAL(dialogClosed()),
 		                        this, SLOT(handleCalendarEditorClosed()));
 		mCalenEditor->edit(mAgendaEntry, false);
-	
+		mCalenEditorClosed = false;
 		
 	}
 	OstTraceFunctionExit0( AGENDAEVENTVIEW_EDIT_EXIT );
@@ -1276,6 +1277,7 @@
     OstTraceFunctionEntry0( AGENDAEVENTVIEW_HANDLECALENDAREDITORCLOSED_ENTRY );
 
 	// Cleanup.
+    mCalenEditorClosed = true;
 	mCalenEditor->deleteLater();
 	mOwner->editingCompleted();
 
@@ -1493,4 +1495,36 @@
     OstTraceFunctionExit0( AGENDAEVENTVIEW_CHANGEDORIENTATION_EXIT );
 }
 
+/*!
+    Close the editor and save the entry.
+    should be call if editor is open
+ */
+void AgendaEventView::saveAndCloseEditor()
+{
+    if(mCalenEditorClosed){
+        QObject *plugin = qobject_cast<QObject*> (
+                mNotesEditorPluginLoader->instance());
+
+        NotesEditorInterface* interface =
+            qobject_cast<NotesEditorInterface*>(plugin);
+
+        
+        interface->close(NotesEditorInterface::CloseWithSave ,mOwner->mAgendaUtil);
+
+    }
+    else{
+        if(mCalenEditor){
+            mCalenEditor->saveAndCloseEditor();
+        }
+    }
+}
+
+/*!
+    Close the view .
+    should be call if view is open
+ */
+void AgendaEventView::closeAgendaEventView()
+{
+    close();  
+}
 // End of file
--- a/calendarui/agendaeventviewer/src/agendaeventviewer.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/agendaeventviewer/src/agendaeventviewer.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -147,4 +147,22 @@
 	OstTraceFunctionExit0( DUP2_AGENDAEVENTVIEWER_VIEW_EXIT );
 }
 
+/*! 
+    save the entry and close the editor
+*/
+void AgendaEventViewer::saveAndCloseEditor()
+{
+    d_ptr->saveAndCloseEditor();
+}
+
+
+/*! 
+    close the aganda event view
+*/
+void AgendaEventViewer::closeAgendaEventView()
+{
+    d_ptr->closeAgendaEventView();   
+}
+
+
 // End of file
--- a/calendarui/agendaeventviewer/src/agendaeventviewer_p.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/agendaeventviewer/src/agendaeventviewer_p.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -275,4 +275,25 @@
     mAction = AgendaEventViewer::ActionNothing;
 	OstTraceFunctionExit0( AGENDAEVENTVIEWERPRIVATE_VIEWCREATIONCOMPLETED_EXIT );
 	}
+
+// ----------------------------------------------------------------------------
+// AgendaEventViewerPrivate::saveAndCloseEditor
+// save the entry and close the editor
+// ----------------------------------------------------------------------------
+//
+void AgendaEventViewerPrivate::saveAndCloseEditor()
+{
+    mAgendaEventView->saveAndCloseEditor();
+}
+
+
+// ----------------------------------------------------------------------------
+// AgendaEventViewerPrivate::closeAgendaEventView
+// close the agenda event view 
+// ----------------------------------------------------------------------------
+//
+void AgendaEventViewerPrivate::closeAgendaEventView()
+{
+    mAgendaEventView->closeAgendaEventView(); 
+}
 // End of file
--- a/calendarui/caleneditor/data/caleneditor.qrc	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/caleneditor/data/caleneditor.qrc	Wed Aug 25 14:02:13 2010 +0530
@@ -1,6 +1,6 @@
 <!DOCTYPE RCC><RCC version="1.0">
 	<qresource prefix="/xml">
 		<file alias="caleneditorview.docml">caleneditorview.docml</file> 	
-		<file alias="caleneditorlocationitem.docml">caleneditorlocationitem.docml</file> 	
+		<file alias="caleneditorcustomitem.css">caleneditorcustomitem.css</file>
 	</qresource>
 </RCC>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/calendarui/caleneditor/data/caleneditorcustomitem.css	Wed Aug 25 14:02:13 2010 +0530
@@ -0,0 +1,22 @@
+CalenEditorCustomItem[!hasIcon][expandItem]:landscape
+{
+    layout:layout_portrait_without_icon;
+}
+
+CalenEditorCustomItem[hasIcon][expandItem]:landscape
+{
+    layout:layout_portrait_with_icon;
+}
+
+CalenEditorCustomItem[expandItem]::dataItem_Label:landscape
+{
+    size-policy-horizontal:preferred;
+}
+
+CalenEditorCustomItem[expandItem]::DataItem_ContentWidget:landscape
+{
+    top: -var(hb-param-margin-gene-top);
+    left:-var(hb-param-margin-gene-left);
+    right:var(hb-param-margin-gene-right);
+    bottom:var(hb-param-margin-gene-bottom);
+}
\ No newline at end of file
--- a/calendarui/caleneditor/data/caleneditorlocationitem.docml	Mon Aug 09 18:30:52 2010 +0530
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<hbdocument version="0.9">
-    <widget name="calenEditorLocationWidget" type="HbWidget">
-        <widget name="locationLineEdit" type="HbLineEdit">
-            <real name="z" value="1"/>
-            <string name="text" value=""/>
-        </widget>
-        <widget name="locationPushButton" type="HbPushButton">
-            <real name="z" value="2"/>
-            <sizehint height="7.4un" type="MINIMUM" width="9.5un"/>
-            <sizehint height="7.4un" type="MAXIMUM" width="9.5un"/>
-        </widget>
-        <rect height="9.4un" name="geometry" width="53.73134un" x="0un" y="0un"/>
-        <sizehint height="9.4un" type="PREFERRED"/>
-        <sizehint height="9.4un" type="MINIMUM"/>
-        <sizehint height="9.4un" type="MAXIMUM"/>
-        <layout type="anchor">
-            <anchoritem dst="locationPushButton" dstEdge="RIGHT" spacing="0un" src="" srcEdge="RIGHT"/>
-            <anchoritem dst="locationPushButton" dstEdge="TOP" spacing="0un" src="" srcEdge="TOP"/>
-            <anchoritem dst="locationLineEdit" dstEdge="LEFT" spacing="0un" src="" srcEdge="LEFT"/>
-            <anchoritem dst="locationLineEdit" dstEdge="RIGHT" spacing="-var(hb-param-margin-gene-middle-horizontal)" src="locationPushButton" srcEdge="LEFT"/>
-            <anchoritem dst="locationLineEdit" dstEdge="CENTERV" spacing="0un" src="locationPushButton" srcEdge="CENTERV"/>
-        </layout>
-    </widget>
-    <metadata activeUIState="Common ui state" display="NHD portrait" unit="un">
-        <uistate name="Common ui state" sections="#common"/>
-    </metadata>
-</hbdocument>
--- a/calendarui/caleneditor/src/caleneditorcustomitem.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/caleneditor/src/caleneditorcustomitem.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -30,6 +30,7 @@
 #include <HbDataFormModel>
 #include <HbAbstractViewItem>
 #include <HbAbstractItemView>
+#include <hbstyleloader.h>
 #include <QGraphicsLinearLayout>
 #include <QDate>
 #include <QTime>
@@ -72,6 +73,7 @@
  mRequestPending(false)
 {
 	OstTraceFunctionEntry0( CALENEDITORCUSTOMITEM_CALENEDITORCUSTOMITEM_ENTRY );
+	HbStyleLoader::registerFilePath(":/xml");
 	mMinDate = CalenDateUtils::minTime().date();
 	mMaxDate = CalenDateUtils::maxTime().date();
 	mMinTime.setHMS(0,0,0,0);
@@ -114,22 +116,43 @@
 	switch (itemType) {
 		case CustomWidgetFrom:
 		{
-		HbWidget *widgetTop = new HbWidget();
-		QGraphicsLinearLayout *layoutTop =
-									new QGraphicsLinearLayout(Qt::Horizontal);
-		widgetTop->setLayout(layoutTop);
+			// Set the property so that the custom item layout
+			// will be the same for both portrait and landscape
+			setProperty("expandItem", true);
+			// Create the widget
+			HbWidget *widgetTop = new HbWidget();
+			QGraphicsLinearLayout *layoutTop =
+								new QGraphicsLinearLayout(Qt::Horizontal);
+			layoutTop->setContentsMargins(0, 0, 0, 0);
+
+			widgetTop->setLayout(layoutTop);
+
+			// Set the button spacing.
+			HbDeviceProfile deviceProfile;
+			// The layout guide specifies the spacing as 2 u.
+			qreal spacing = deviceProfile.unitValue() * 2 ;
+			layoutTop->setSpacing(spacing);
+			// Calculate the button width.
+			qreal right = 0.0;
+			qreal left = 0.0;
+			style()->parameter("hb-param-margin-gene-right", right);
+			style()->parameter("hb-param-margin-gene-left", left);
+			qreal screenWidth = 0.0;
+			style()->parameter("hb-param-screen-short-edge", screenWidth);
+			qreal buttonWidth = (screenWidth - right - left - spacing) / 2;
 
 			mPushButtonTime = new HbPushButton();
+			mPushButtonTime->setPreferredWidth(buttonWidth);
 			mPushButtonTime->setObjectName("startTime");
 			connect(mPushButtonTime, SIGNAL(clicked()),
-									this, SLOT(handleTime()));
+													this, SLOT(handleTime()));
 			layoutTop->addItem(mPushButtonTime);
 
-			mPushButtonDate =
-			                new HbPushButton();
+			mPushButtonDate = new HbPushButton();
+			mPushButtonDate->setPreferredWidth(buttonWidth);
 			mPushButtonDate->setObjectName("startDate");
 			connect(mPushButtonDate, SIGNAL(clicked()),
-												this, SLOT(handleDate()));
+													this, SLOT(handleDate()));
 			layoutTop->addItem(mPushButtonDate);
 			OstTraceFunctionExit0( CALENEDITORCUSTOMITEM_CREATECUSTOMWIDGET_EXIT );
 			return widgetTop;
@@ -138,72 +161,103 @@
 
 		case CustomWidgetTo:
 		{
-		HbWidget *widgetBottom = new HbWidget();
-		QGraphicsLinearLayout *layoutBottom = 
-									new QGraphicsLinearLayout(Qt::Horizontal);
-		widgetBottom->setLayout(layoutBottom);
+			// Set the property so that the custom item layout
+			// will be the same for both portrait and landscape
+			setProperty("expandItem", true);
+			// Create the widget
+			HbWidget *widgetBottom = new HbWidget();
+			
+			QGraphicsLinearLayout *layoutBottom = 
+					new QGraphicsLinearLayout(Qt::Horizontal);
+			layoutBottom->setContentsMargins(0, 0, 0, 0);
+			widgetBottom->setLayout(layoutBottom);
 
-		mPushButtonTime = new HbPushButton(this);
-		mPushButtonTime->setObjectName("endTime");
-		connect(mPushButtonTime, SIGNAL(clicked()),
-											this, SLOT(handleTime()));
-		layoutBottom->addItem(mPushButtonTime);
-		
-		mPushButtonDate = new HbPushButton(this);
-		mPushButtonDate->setObjectName("endDate");
-		connect(mPushButtonDate, SIGNAL(clicked()),
-												this, SLOT(handleDate()));
-		layoutBottom->addItem(mPushButtonDate);
+			// Set the button spacing.
+			HbDeviceProfile deviceProfile;
+			// The layout guide specifies the spacing as 2 u.
+			qreal spacing = deviceProfile.unitValue() * 2 ;
+			layoutBottom->setSpacing(spacing);
+			// Calculate the button width.
+			qreal right = 0.0;
+			qreal left = 0.0;
+			style()->parameter("hb-param-margin-gene-right", right);
+			style()->parameter("hb-param-margin-gene-left", left);
+			qreal screenWidth = 0.0;
+			style()->parameter("hb-param-screen-short-edge", screenWidth);
+			qreal buttonWidth = (screenWidth - right - left - spacing) / 2;
+
+			mPushButtonTime = new HbPushButton(this);
+			mPushButtonTime->setPreferredWidth(buttonWidth);
+			mPushButtonTime->setObjectName("endTime");
+			connect(mPushButtonTime, SIGNAL(clicked()),
+													this, SLOT(handleTime()));
+			layoutBottom->addItem(mPushButtonTime);
+
+			mPushButtonDate = new HbPushButton(this);
+			mPushButtonDate->setPreferredWidth(buttonWidth);
+			mPushButtonDate->setObjectName("endDate");
+			connect(mPushButtonDate, SIGNAL(clicked()),
+													this, SLOT(handleDate()));
+			layoutBottom->addItem(mPushButtonDate);
 			OstTraceFunctionExit0( DUP1_CALENEDITORCUSTOMITEM_CREATECUSTOMWIDGET_EXIT );
-		return widgetBottom;
+			return widgetBottom;
 		}
 				
 		case CustomWidgetLocation:
 		{
-			CalenEditorDocLoader editorLocationDocLoader;
-			bool loadSuccess = false;
-
-			editorLocationDocLoader.load(CALEN_EDITOR_LOCATION_XML_FILE, 
-														&loadSuccess);
-			Q_ASSERT_X(loadSuccess, "caleneditor.cpp", 
-								"Unable to load caleneditor location view XML");
-			HbWidget* widgetLocation = qobject_cast<HbWidget *> (
-					editorLocationDocLoader.findWidget(CALEN_EDITOR_LOCATION));
-
-			mLocationLineEdit = qobject_cast<HbLineEdit *>( 
-									editorLocationDocLoader.findWidget(
-											CALEN_EDITOR_LOCATION_LINEEDIT));
+			setProperty("expandItem", false);
+			HbWidget *widgetLocation = new HbWidget();
+			QGraphicsLinearLayout *layoutLocation = 
+										new QGraphicsLinearLayout(Qt::Horizontal);
+			layoutLocation->setContentsMargins(0, 0, 0, 0);
+			widgetLocation->setLayout(layoutLocation);
+			
+			// Set the spacing between LineEdit and PushButton
+			qreal spacing = 0.0;
+			style()->parameter(
+							"hb-param-margin-gene-middle-horizontal", spacing);
+			layoutLocation->setSpacing(spacing);
+			
+			mLocationLineEdit = new HbLineEdit(this);
 			mLocationLineEdit->setObjectName("locationLineEdit");
-			mLocationLineEdit->setMinRows(1);
 			mLocationLineEdit->setMaxRows(MaxRowsInTextItem);
-			mLocationPushButton = qobject_cast<HbPushButton*>(
-									editorLocationDocLoader.findWidget(
-											CALEN_EDITOR_LOCATION_PUSHBUTTON));
+			connect(mLocationLineEdit, SIGNAL(textChanged(const QString)),
+						this, SLOT(handleLocationTextChange(const QString)));
+			connect(mLocationLineEdit, SIGNAL(editingFinished()),
+						this, SLOT(handleEditingFinished()));
+			layoutLocation->addItem(mLocationLineEdit);
+			
+			mLocationPushButton = new HbPushButton(this);
+			
+			HbDeviceProfile deviceProfile;
+			// The layout guide specifies the spacing as 9.5 u 
+			// and the height as 7.4 u
+			qreal width = deviceProfile.unitValue() * 9.5;
+			qreal height = deviceProfile.unitValue() * 7.4 ;
+			mLocationPushButton->setPreferredSize(width, height);
+			mLocationPushButton->setSizePolicy(
+										QSizePolicy::Fixed, QSizePolicy::Fixed);
+			mLocationPushButton->setIcon( HbIcon("qtg_mono_location"));
 			mLocationPushButton->setObjectName("locationIcon");
-			mLocationPushButton->setIcon( HbIcon("qtg_mono_location"));
-			
 			connect(mLocationPushButton, SIGNAL(clicked()), this, 
 												SLOT(launchLocationPicker()));
-			connect(mLocationLineEdit, SIGNAL(textChanged(const QString)),
-						this, SLOT(handleLocationTextChange(const QString)));
-						
-			connect(mLocationLineEdit, SIGNAL(editingFinished()),
-			            this, SLOT(handleEditingFinished()));
-			
+			layoutLocation->addItem(mLocationPushButton);
 			OstTraceFunctionExit0( DUP2_CALENEDITORCUSTOMITEM_CREATECUSTOMWIDGET_EXIT );
 			return widgetLocation;
 		}
 		
 		case RepeatUntilOffset:
 		{
-		mRepeatUntilWidget = new HbPushButton(this);
-		mRepeatUntilWidget->setObjectName("repeatUntilItem");
-		OstTraceFunctionExit0( DUP3_CALENEDITORCUSTOMITEM_CREATECUSTOMWIDGET_EXIT );
-		return mRepeatUntilWidget;
+			setProperty("expandItem", false);
+			mRepeatUntilWidget = new HbPushButton(this);
+			mRepeatUntilWidget->setObjectName("repeatUntilItem");
+			OstTraceFunctionExit0( DUP3_CALENEDITORCUSTOMITEM_CREATECUSTOMWIDGET_EXIT );
+			return mRepeatUntilWidget;
 		}
 				
 		case ReminderTimeOffset:
 		{
+			setProperty("expandItem", false);
 			mReminderTimeWidget = new HbPushButton(this);
 			mReminderTimeWidget->setObjectName("remainderTimeItem");
 			OstTraceFunctionExit0( DUP4_CALENEDITORCUSTOMITEM_CREATECUSTOMWIDGET_EXIT );
--- a/calendarui/caleneditor/src/caleneditorreminderfield.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/caleneditor/src/caleneditorreminderfield.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -205,13 +205,6 @@
 			if (pastEvent && mReminderTimeAdded) {
 				mCustomReminderTimeItem->setEnabled(false);
 			}
-			QStringList reminderChoicesForAllDay;
-			reminderChoicesForAllDay << hbTrId("txt_calendar_setlabel_reminder_val_off") 
-					<< hbTrId("txt_calendar_setlabel_reminder_val_on_event_day")
-					<< hbTrId("txt_calendar_setlabel_reminder_val_1_day_before")
-					<< hbTrId("txt_calendar_setlabel_reminder_val_2_days_before");
-			mReminderItem->setContentWidgetData(QString("items"),
-			                                    reminderChoicesForAllDay);
 			QTime referenceTime(0, 0, 0);
 			// Set the appropriate reminder depending on the value of time offset.
 			reminder = mCalenEditor->editedEntry()->alarm();
@@ -220,7 +213,7 @@
 				mReminderItem->setContentWidgetData("currentIndex", ReminderOnEventDay);
 				mReminderTimeForAllDay = referenceTime.addSecs(-(offsetInMins
 						* 60));
-			} else if (offsetInMins < numberOfMinutesInADay) {
+			} else if (offsetInMins <= numberOfMinutesInADay) {
 				mReminderItem->setContentWidgetData("currentIndex", ReminderOneDayBefore);
 				mReminderTimeForAllDay = referenceTime.addSecs(-(offsetInMins
 						* 60));
@@ -549,6 +542,8 @@
 {
 	OstTraceFunctionEntry0( CALENEDITORREMINDERFIELD_REMOVEREMINDERTIMEFIELD_ENTRY );
 	mReminderTimeAdded = false;
+	mEditorForm->removeConnection(mCustomReminderTimeItem, SIGNAL(clicked()),
+		                           this, SLOT(launchReminderTimePicker()));
 	if (mCustomReminderTimeItem) {
 		QModelIndex reminderIndex =
 				mCalenEditorModel->indexFromItem(mCustomReminderTimeItem);
--- a/calendarui/caleneditor/src/caleneditorrepeatfield.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/caleneditor/src/caleneditorrepeatfield.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -290,102 +290,108 @@
 		repeatPropertyChange = false;
 	}
 	QDate repeatUntilDate = mRepeatUntilDate;
-
-	if (value != mRepeatRoleValue)
-	{
-	    mRepeatRoleValue = value;
-	    switch (value) {
-		case DailyRole: {
-			if (!mRepeatUntilItemAdded) {
-				insertRepeatUntilItem();
+	// Update the repeat type only if its has been changed
+	// ie. if the previous repeatrole is different from the current repeat role
+	if (value != mRepeatRoleValue) {
+		mRepeatRoleValue = value;
+		switch (value) {
+			case DailyRole: {
+				if (!mRepeatUntilItemAdded) {
+					insertRepeatUntilItem();
+				}
+				if (mCustomRepeatUntilItem) {
+					// Show default repeat until date till one year for daily rule 
+					mRepeatUntilDate = 
+						mCalenEditor->editedEntry()->startTime().date().addYears(1);
+					mCustomRepeatUntilItem->setContentWidgetData( "text", 
+						locale.format( 
+								mRepeatUntilDate, r_qtn_date_usual_with_zero));
+				}
+				mRepeatRuleType = AgendaRepeatRule::DailyRule;
 			}
-			if (mCustomRepeatUntilItem) {
-				// Show default repeat until date till one year for daily rule 
-				mRepeatUntilDate = mCalenEditor->editedEntry()->startTime().date().addYears(1);
-				mCustomRepeatUntilItem->setContentWidgetData( "text", 
-												locale.format( mRepeatUntilDate,
-												r_qtn_date_usual_with_zero));
+			break;
+			case WorkdaysRole: {
+				if (!mRepeatUntilItemAdded) {
+					insertRepeatUntilItem();
+				}
+				if (mCustomRepeatUntilItem) {
+					// Show default repeat until date till one year for workdays rule
+					mRepeatUntilDate = 
+						mCalenEditor->editedEntry()->startTime().date().addYears(1);
+					mCustomRepeatUntilItem->setContentWidgetData( "text",
+						locale.format( 
+								mRepeatUntilDate, r_qtn_date_usual_with_zero));
+				}
+				mRepeatRuleType = AgendaRepeatRule::WeeklyRule;
+				mIsWorkdays = true;
 			}
-			mRepeatRuleType = AgendaRepeatRule::DailyRule;
-		}
-		break;
-		case WorkdaysRole: {
-			if (!mRepeatUntilItemAdded) {
-				insertRepeatUntilItem();
+			break;
+			case WeeklyRole: {
+				if (!mRepeatUntilItemAdded) {
+					insertRepeatUntilItem();
+				}
+				if (mCustomRepeatUntilItem) {
+					// Show default repeat until date till one year for weekly rule
+					mRepeatUntilDate = 
+						mCalenEditor->editedEntry()->startTime().date().addYears(1);
+					mCustomRepeatUntilItem->setContentWidgetData( "text",
+						locale.format( 
+								mRepeatUntilDate, r_qtn_date_usual_with_zero));
+				}
+				mRepeatRuleType = AgendaRepeatRule::WeeklyRule;
 			}
-			if (mCustomRepeatUntilItem) {
-				// Show default repeat until date till one year for workdays rule
-				mRepeatUntilDate = mCalenEditor->editedEntry()->startTime().date().addYears(1);
-				mCustomRepeatUntilItem->setContentWidgetData( "text",
-												locale.format( mRepeatUntilDate,
-												r_qtn_date_usual_with_zero));
+			break;
+			case BiWeeklyRole: {
+				if (!mRepeatUntilItemAdded) {
+					insertRepeatUntilItem();
+				}
+				if (mCustomRepeatUntilItem) {
+					// Show default repeat until date till one year for bi-weekly rule
+					mRepeatUntilDate = 
+						mCalenEditor->editedEntry()->startTime().date().addYears(1);
+					mCustomRepeatUntilItem->setContentWidgetData( "text",
+						locale.format( 
+							mRepeatUntilDate, r_qtn_date_usual_with_zero));
+				}
+				mRepeatRuleType = AgendaRepeatRule::WeeklyRule;
+				mIsBiWeekly = true;
 			}
-			mRepeatRuleType = AgendaRepeatRule::WeeklyRule;
-			mIsWorkdays = true;
-		}
-		break;
-		case WeeklyRole: {
-			if (!mRepeatUntilItemAdded) {
-				insertRepeatUntilItem();
+			break;
+			case MonthlyRole: {
+				if (!mRepeatUntilItemAdded) {
+					insertRepeatUntilItem();
+				}
+				if (mCustomRepeatUntilItem) {
+					// Show default repeat until date till one year for monthly rule
+					mRepeatUntilDate = 
+						mCalenEditor->editedEntry()->startTime().date().addYears(1);
+					mCustomRepeatUntilItem->setContentWidgetData( "text",
+						locale.format(
+								mRepeatUntilDate, r_qtn_date_usual_with_zero));
+				}
+				mRepeatRuleType = AgendaRepeatRule::MonthlyRule;
 			}
-			if (mCustomRepeatUntilItem) {
-				// Show default repeat until date till one year for weekly rule
-				mRepeatUntilDate = mCalenEditor->editedEntry()->startTime().date().addYears(1);
-				mCustomRepeatUntilItem->setContentWidgetData( "text",
-												locale.format( mRepeatUntilDate,
-												r_qtn_date_usual_with_zero));
+			break;
+			case YearlyRole: {
+				if (!mRepeatUntilItemAdded) {
+					insertRepeatUntilItem();
+				}
+				if (mCustomRepeatUntilItem) {
+					// Show default repeat until date till ten years for yearly rule
+					mRepeatUntilDate = 
+						mCalenEditor->editedEntry()->startTime().date().addYears(10);
+					mCustomRepeatUntilItem->setContentWidgetData( "text",
+						locale.format(
+							mRepeatUntilDate, r_qtn_date_usual_with_zero));
+				}
+				mRepeatRuleType = AgendaRepeatRule::YearlyRule;
 			}
-			mRepeatRuleType = AgendaRepeatRule::WeeklyRule;
+			break;
+			default: {
+				removeRepeatUntilItem();
+			}
+			break;
 		}
-		break;
-		case BiWeeklyRole: {
-			if (!mRepeatUntilItemAdded) {
-				insertRepeatUntilItem();
-			}
-			if (mCustomRepeatUntilItem) {
-				// Show default repeat until date till one year for bi-weekly rule
-				mRepeatUntilDate = mCalenEditor->editedEntry()->startTime().date().addYears(1);
-				mCustomRepeatUntilItem->setContentWidgetData( "text",
-												locale.format( mRepeatUntilDate,
-												r_qtn_date_usual_with_zero));
-			}
-			mRepeatRuleType = AgendaRepeatRule::WeeklyRule;
-			mIsBiWeekly = true;
-		}
-		break;
-		case MonthlyRole: {
-			if (!mRepeatUntilItemAdded) {
-				insertRepeatUntilItem();
-			}
-			if (mCustomRepeatUntilItem) {
-				// Show default repeat until date till one year for monthly rule
-				mRepeatUntilDate = mCalenEditor->editedEntry()->startTime().date().addYears(1);
-				mCustomRepeatUntilItem->setContentWidgetData( "text",
-												locale.format( mRepeatUntilDate,
-												r_qtn_date_usual_with_zero));
-			}
-			mRepeatRuleType = AgendaRepeatRule::MonthlyRule;
-		}
-		break;
-		case YearlyRole: {
-			if (!mRepeatUntilItemAdded) {
-				insertRepeatUntilItem();
-			}
-			if (mCustomRepeatUntilItem) {
-				// Show default repeat until date till ten years for yearly rule
-				mRepeatUntilDate = mCalenEditor->editedEntry()->startTime().date().addYears(10);
-				mCustomRepeatUntilItem->setContentWidgetData( "text",
-												locale.format( mRepeatUntilDate,
-												r_qtn_date_usual_with_zero));
-			}
-			mRepeatRuleType = AgendaRepeatRule::YearlyRule;
-		}
-		break;
-		default: {
-			removeRepeatUntilItem();
-		}
-		break;
-	}
 	}
 	if(!mCalenEditor->isNewEntry()) {
 		mCalenEditor->addDiscardAction();
@@ -668,8 +674,17 @@
 	//Connecting back the slot for repeat index change before setting index.
 	connect(mRepeatComboBox, SIGNAL(currentIndexChanged(int)), this,
 				SLOT(handleRepeatIndexChanged(int)));
+	// By default the repeat combobox index will be 0
 	// Set the previous user's choice
 	mRepeatComboBox->setCurrentIndex(choice);
+	// If the previous user's choice is also zero, then slot 
+	// handleRepeatIndexChanged will not be called as 
+	// there is no change in current index
+	// So explicitly call updateReminderChoices to update the reminder choices
+	// for choice : 0 (Not repeated)
+	if(choice == 0) {
+		mCalenEditor->updateReminderChoices();
+	}
 	OstTraceFunctionExit0( DUP1_CALENEDITORREPEATFIELD_UPDATEREPEATCHOICES_EXIT );
 }
 
--- a/calendarui/controller/data/xml/calendayview.docml	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/controller/data/xml/calendayview.docml	Wed Aug 25 14:02:13 2010 +0530
@@ -3,20 +3,20 @@
     <widget name="dayView" type="HbView">
         <widget name="dayViewDayInfo" type="HbGroupBox">
             <bool name="collapsable" value="FALSE"/>
-        </widget>
-        <widget name="dayViewRegionalInfo" type="HbGroupBox">
-            <bool name="collapsable" value="FALSE"/>
+            <real name="z" value="4"/>
         </widget>
         <widget name="dayViewContentWidget" type="HbWidget">
 			<widget name="dayViewHourScrollArea" type="HbScrollArea">
 				<enums name="verticalScrollBarPolicy" value="ScrollBarAlwaysOff"/>
+				<real name="z" value="3"/>
 			</widget>
 			<widget name="dayViewContentScrollArea" type="HbScrollArea">
 				<enums name="scrollDirections" value="Horizontal"/>
 				<enums name="horizontalScrollBarPolicy" value="ScrollBarAlwaysOff"/>
 				<enums name="clampingStyle" value="StrictClamping"/>
+				<real name="z" value="2"/>
 			</widget>
-			<real name="z" value="0"/>
+			<real name="z" value="1"/>
 			<layout orientation="Horizontal" spacing="0un" type="linear">
 				<contentsmargins bottom="0un" left="0un" right="0un" top="0un"/>
 				<linearitem itemname="dayViewHourScrollArea"/>
@@ -27,10 +27,8 @@
         <layout orientation="Vertical" spacing="0un" type="linear">
             <contentsmargins bottom="0un" left="0un" right="0un" top="0un"/>
             <linearitem itemname="dayViewDayInfo"/>
-            <linearitem itemname="dayViewRegionalInfo"/>
             <linearitem itemname="dayViewContentWidget"/>
         </layout>
-        <string name="title" value="Day view"/>
     </widget>
     <metadata activeUIState="Common ui state" display="QHD portrait" unit="un">
         <uistate name="Common ui state" sections="#common"/>
--- a/calendarui/controller/data/xml/calenmonthview.docml	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/controller/data/xml/calenmonthview.docml	Wed Aug 25 14:02:13 2010 +0530
@@ -23,7 +23,6 @@
             <widget name="monthViewExceptPreviewPane" type="HbWidget">
                 <widget name="monthTitle" type="HbLabel">
                     <enums name="alignment" value="AlignVCenter|AlignHCenter"/>
-					<string name="textColor" value="qtc_cal_monthgrid_title"/>
 					<fontspec name="fontSpec" role="Secondary" textheight="var(hb-param-text-height-secondary)"/>
                     <real name="z" value="6"/>
                     <sizehint height="expr(var(hb-param-text-height-secondary) + 0.75un + 0.75un)" type="PREFERRED" width="52un"/>
@@ -33,44 +32,37 @@
                 </widget>
                 <widget name="dayNamesWidget" type="HbWidget">
                     <widget name="firstDayLabel" type="HbLabel">
-                        <enums name="alignment" value="AlignVCenter|AlignHCenter"/>
-						<string name="textColor" value="qtc_cal_week_day"/>
+                        <enums name="alignment" value="AlignVCenter|AlignHCenter"/>						
                         <real name="z" value="6"/>
                         <fontspec name="fontSpec" role="Secondary" textheight="var(hb-param-text-height-tiny)"/>
                     </widget>
                     <widget name="secondDayLabel" type="HbLabel">
-                        <enums name="alignment" value="AlignVCenter|AlignHCenter"/>
-						<string name="textColor" value="qtc_cal_week_day"/>
+                        <enums name="alignment" value="AlignVCenter|AlignHCenter"/>						
                         <real name="z" value="6"/>
                         <fontspec name="fontSpec" role="Secondary" textheight="var(hb-param-text-height-tiny)"/>
                     </widget>
                     <widget name="thirdDayLabel" type="HbLabel">
-                        <enums name="alignment" value="AlignVCenter|AlignHCenter"/>
-						<string name="textColor" value="qtc_cal_week_day"/>
+                        <enums name="alignment" value="AlignVCenter|AlignHCenter"/>						
                         <real name="z" value="6"/>
                         <fontspec name="fontSpec" role="Secondary" textheight="var(hb-param-text-height-tiny)"/>
                     </widget>
                     <widget name="fourthDayLabel" type="HbLabel">
-                        <enums name="alignment" value="AlignVCenter|AlignHCenter"/>
-						<string name="textColor" value="qtc_cal_week_day"/>
+                        <enums name="alignment" value="AlignVCenter|AlignHCenter"/>						
                         <real name="z" value="6"/>
                         <fontspec name="fontSpec" role="Secondary" textheight="var(hb-param-text-height-tiny)"/>
                     </widget>
                     <widget name="fifthDayLabel" type="HbLabel">
-                        <enums name="alignment" value="AlignVCenter|AlignHCenter"/>
-						<string name="textColor" value="qtc_cal_week_day"/>
+                        <enums name="alignment" value="AlignVCenter|AlignHCenter"/>						
                         <real name="z" value="6"/>
                         <fontspec name="fontSpec" role="Secondary" textheight="var(hb-param-text-height-tiny)"/>
                     </widget>
                     <widget name="sixthDayLabel" type="HbLabel">
-                        <enums name="alignment" value="AlignVCenter|AlignHCenter"/>
-						<string name="textColor" value="qtc_cal_week_day"/>
+                        <enums name="alignment" value="AlignVCenter|AlignHCenter"/>						
                         <real name="z" value="6"/>
                         <fontspec name="fontSpec" role="Secondary" textheight="var(hb-param-text-height-tiny)"/>
                     </widget>
                     <widget name="seventhDayLabel" type="HbLabel">
-                        <enums name="alignment" value="AlignVCenter|AlignHCenter"/>
-						<string name="textColor" value="qtc_cal_week_day"/>
+                        <enums name="alignment" value="AlignVCenter|AlignHCenter"/>						
                         <real name="z" value="6"/>
                         <fontspec name="fontSpec" role="Secondary" textheight="var(hb-param-text-height-tiny)"/>
                     </widget>
@@ -169,7 +161,6 @@
 					<widget name="prevRegionalInfo" type="HbLabel">
 					<enums name="alignment" value="AlignCenter"/>
 					<fontspec name="fontSpec" role="Secondary" textheight="var(hb-param-text-height-secondary)"/>
-					<string name="textColor" value="qtc_cal_day_preview_heading"/>
 					<contentsmargins bottom="0.75un" left="var(hb-param-margin-gene-left)" right="var(hb-param-margin-gene-right)" top="0.75un"/>
 					</widget>
 	                <widget name="prevPaneLayout" type="HbWidget">
@@ -227,7 +218,6 @@
 					<widget name="currRegionalInfo" type="HbLabel">
 					<enums name="alignment" value="AlignCenter"/>
 					<fontspec name="fontSpec" role="Secondary" textheight="var(hb-param-text-height-secondary)"/>
-					<string name="textColor" value="qtc_cal_day_preview_heading"/>
 					<contentsmargins bottom="0.75un" left="var(hb-param-margin-gene-left)" right="var(hb-param-margin-gene-right)" top="0.75un"/>
 					</widget>
                     <widget name="currPaneLayout" type="HbWidget">
@@ -285,7 +275,6 @@
 					<widget name="nextRegionalInfo" type="HbLabel">
 					<enums name="alignment" value="AlignCenter"/>
 					<fontspec name="fontSpec" role="Secondary" textheight="var(hb-param-text-height-secondary)"/>
-					<string name="textColor" value="qtc_cal_day_preview_heading"/>
 					<contentsmargins bottom="0.75un" left="var(hb-param-margin-gene-left)" right="var(hb-param-margin-gene-right)" top="0.75un"/>
 					</widget>
                     <widget name="nextPaneLayout" type="HbWidget">
--- a/calendarui/controller/inc/calenviewmanager.h	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/controller/inc/calenviewmanager.h	Wed Aug 25 14:02:13 2010 +0530
@@ -103,7 +103,28 @@
 		void constructOtherViews();
 		
 		void launchSettingsView();
+				
+		/**
+		 * @brief check if Agenda Event Viewer is active
+		 */
+		bool isEventViewerActive();
+
+		/**
+		 * save the entry and close the editor
+		 */
+		void saveAndCloseEditor();
 		
+
+        /**
+         * close agenda event view
+         * should be call if agenda eevent view is open
+         */
+		void closeAgendaEventView();
+        
+		/**
+         * remove the setting view
+         */
+		void removeSettingsView();
 		
 	public: // from MCalenNotificationHandler
    
--- a/calendarui/controller/src/calencontroller.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/controller/src/calencontroller.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -644,6 +644,8 @@
 		// launch the appropriate view
 		iViewManager->constructAndActivateView(view);
 		
+		iIsFromServiceFrmWrk = false;
+		
 	} else { // Calendar was in backgroung but now its being brought to foreground
 		// If current state is editing state or printing state
 		// or deleting state or sending state, then dont do anything as
@@ -654,11 +656,28 @@
 			(currentState == CCalenStateMachine::ECalenSendingState)) {
 			// simply return - we dont have anything to do
 		} 
+
+		else if (currentState == CCalenStateMachine::ECalenViewingState) {
+             if(iViewManager->isEventViewerActive()){
+		         iViewManager->closeAgendaEventView();
+		        }
+		}
 		else if (currentState == CCalenStateMachine::ECalenEditingState) {
-			// close the editor and save the entry
+			// close the editor and save the entry if application is in background
             //and launch the desired view
-            iActionUi->saveAndCloseEditor();
+            if(iViewManager->isEventViewerActive()){
+                iViewManager->saveAndCloseEditor();
+                iViewManager->closeAgendaEventView();
+               }
+            else{
+                iActionUi->saveAndCloseEditor();
+            }
 		} 
+
+		else if (currentState == CCalenStateMachine::ECalenSettingsState){
+            iViewManager->removeSettingsView();
+	        }
+ 
 		// Set the context properly
 		mContext->setFocusDateAndTime(dateTime);
 		IssueCommandL(view);
--- a/calendarui/controller/src/calendocloader.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/controller/src/calendocloader.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -153,10 +153,6 @@
 	        QObject *calenDayInfo = new HbGroupBox();
 	        calenDayInfo->setObjectName(name);
 	        return calenDayInfo;
-	} else if (name == QString(CALEN_DAYVIEW_REGIONALINFO)) {
-        QObject *calenRegionalInfo = new HbGroupBox();
-        calenRegionalInfo->setObjectName(name);
-        return calenRegionalInfo;
     } else if (name == QString(CALEN_DAYVIEW_CONTENTWIDGET)) {
         QObject *calenContentWidget = new HbWidget();
         calenContentWidget->setObjectName(name);
--- a/calendarui/controller/src/calenviewmanager.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/controller/src/calenviewmanager.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -944,10 +944,12 @@
 	// solution for the month view implements the construction in two phases so 
 	// it needs to be refactored and a common solution needs to be put here. So 
 	// that code doesn't break if another view is added tomorow
-	if (mCalenMonthView) {
+	HbView *currentview = mController.MainWindow().currentView();
+	
+	if (mCalenMonthView && currentview == mCalenMonthView) {
 		mCalenMonthView->fetchEntriesAndUpdateModel();
 	}
-	else if (mCalenAgendaView) {
+	else if (mCalenAgendaView && currentview == mCalenAgendaView) {
 		mCalenAgendaView->doPopulation();
 	}
 	// Calls the emitAppReady function of CalenController. Need to emit this
@@ -1039,4 +1041,53 @@
     OstTraceFunctionExit0( CALENVIEWMANAGER_LAUNCHSETTINGSVIEW_EXIT );
 }
 
+
+// ----------------------------------------------------------------------------
+// CalenViewManager::removeSettingsView
+// remove settings view
+// ----------------------------------------------------------------------------
+//
+void CalenViewManager::removeSettingsView()
+{
+    if(mSettingsView){
+        mController.Services().MainWindow().removeView(mSettingsView);
+    }
+}
+    
+// ----------------------------------------------------------------------------
+// CalenViewManager::isEventViewerActive
+// check if Agenda Event Viewer is active
+// ----------------------------------------------------------------------------
+//
+bool CalenViewManager::isEventViewerActive()
+{
+   if(mCalenEventViewer)
+       return true;
+   else
+       return false;
+}
+
+// ----------------------------------------------------------------------------
+// CalenViewManager::saveAndCloseEditor
+// save the entry and close the editor
+// isEventViewerActive() should be called before this function
+// ----------------------------------------------------------------------------
+//
+void CalenViewManager::saveAndCloseEditor()
+{
+   mCalenEventViewer->saveAndCloseEditor();
+}
+
+// ----------------------------------------------------------------------------
+// CalenViewManager::closeAgendaEventView
+// close the agenda event view 
+// isEventViewerActive() should be called before this function
+// ----------------------------------------------------------------------------
+//
+void CalenViewManager::closeAgendaEventView()
+{
+   mCalenEventViewer->closeAgendaEventView();
+}
+
+
 // End of file	--Don't remove this.
--- a/calendarui/inc/calencommon.h	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/inc/calencommon.h	Wed Aug 25 14:02:13 2010 +0530
@@ -81,7 +81,6 @@
 #define CALEN_DAYVIEW_DOCML ":/xml/calendayview.docml"
 #define CALEN_DAYVIEW "dayView"
 #define CALEN_DAYVIEW_DAYINFO "dayViewDayInfo"
-#define CALEN_DAYVIEW_REGIONALINFO "dayViewRegionalInfo"
 #define CALEN_DAYVIEW_CONTENTWIDGET "dayViewContentWidget"
 #define CALEN_DAYVIEW_HOURSCROLLAREA "dayViewHourScrollArea"
 #define CALEN_DAYVIEW_CONTENTSCROLLAREA "dayViewContentScrollArea"
--- a/calendarui/views/bwins/calenviewsu.def	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/bwins/calenviewsu.def	Wed Aug 25 14:02:13 2010 +0530
@@ -199,4 +199,11 @@
 	?moveFinished@CalenDayContentScrollArea@@AAEXXZ @ 198 NONAME ; void CalenDayContentScrollArea::moveFinished(void)
 	?scrollToHour@CalenDayHourScrollArea@@QAEXH@Z @ 199 NONAME ; void CalenDayHourScrollArea::scrollToHour(int)
 	??1CalenDayContentScrollArea@@UAE@XZ @ 200 NONAME ; CalenDayContentScrollArea::~CalenDayContentScrollArea(void)
+	?handleThemeChange@CalenMonthGrid@@AAEXXZ @ 201 NONAME ; void CalenMonthGrid::handleThemeChange(void)
+	?effectStarted@CalenPreviewPane@@QAEXXZ @ 202 NONAME ; void CalenPreviewPane::effectStarted(void)
+	?handleThemeChange@CalenThickLinesDrawer@@AAEXXZ @ 203 NONAME ; void CalenThickLinesDrawer::handleThemeChange(void)
+	?effectFinished@CalenPreviewPane@@QAEXXZ @ 204 NONAME ; void CalenPreviewPane::effectFinished(void)
+	?handleThemeChange@CalenMonthView@@AAEXXZ @ 205 NONAME ; void CalenMonthView::handleThemeChange(void)
+	?isHorizontalSwipe@CalenDayContentScrollArea@@ABE_NM@Z @ 206 NONAME ; bool CalenDayContentScrollArea::isHorizontalSwipe(float) const
+	?handleThemeChange@CalenPreviewPane@@QAEXXZ @ 207 NONAME ; void CalenPreviewPane::handleThemeChange(void)
 
--- a/calendarui/views/dayview/inc/calendaycommonheaders.h	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/dayview/inc/calendaycommonheaders.h	Wed Aug 25 14:02:13 2010 +0530
@@ -44,12 +44,12 @@
 /*!
  The minimum width [un] of touchable event bubble (UI spec)
  */
-const qreal KCalenMinTouchableEventWidth = 8.2;
+const qreal KCalenMinTouchableEventWidth = 8.0;
 
 /*!
  The minimum width [un] of event bubble (UI spec)
  */
-const qreal KCalenMinBubbleWidth = 3.0;
+const qreal KCalenMinEventWidth = 3.0;
 
 /*!
  The width [un] of time strip (indicator) in event bubble (UI spec)
@@ -57,11 +57,16 @@
 const qreal KCalenTimeStripWidth = 1.5;
 
 /*!
- The width [un] of space beetwen event buubles in Day View (UI spec)
+ The width [un] of space beetwen event bubbles in Day View (UI spec)
  */
 const qreal KCalenSpaceBeetwenEvents = 1.5;
 
 /*!
+ The minimum width [un] of space beetwen event bubbles in Day View (UI spec)
+ */
+const qreal KCalenMinSpaceBeetwenEvents = 0.1;
+
+/*!
  Number of All day events displayed in single day that remains touchable 
  in portrait orientation (UI spec)
  */
@@ -79,12 +84,17 @@
 const qreal KCalenHourLineThickness = 0.15;
 
 /*!
- Thickness [un] of time line (UI spec)
+ Thickness [un] of current time line (UI spec)
  */
-const qreal KCalenTimeLineThickness = 0.75;
+const qreal KCalenCurrentTimeLineThickness = 0.75;
 
 /*!
- Color scheme for hour line (UI spec)
+ Width [un] of dashes in half-hour line (UI spec)
+ */
+const qreal KCalenHalfHourLineDashWidth = 1.5;
+
+/*!
+ Color scheme for hour and half-hour lines (UI spec)
  */
 const QString KCalenHourLineColor = "qtc_cal_day_hour_lines";
 
@@ -93,6 +103,16 @@
  */
 const QString KCalenTimeLineColor = "qtc_cal_month_current_day";
 
+/*!
+ Color scheme for Day View background in portrait mode (UI spec)
+ */
+const QString KCalenBackgroundColorPortrait = "qtg_graf_cal_bg_prt";
+
+/*!
+ Color scheme for Day View background in landscape mode (UI spec)
+ */
+const QString KCalenBackgroundColorLandscape = "qtg_graf_cal_bg_lsc";
+
 
 // Enumerations
 
--- a/calendarui/views/dayview/inc/calendaycontentscrollarea.h	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/dayview/inc/calendaycontentscrollarea.h	Wed Aug 25 14:02:13 2010 +0530
@@ -19,7 +19,7 @@
 #define CALENDAYCONTENTSCROLLAREA_H_
 
 // System includes
-#include <hbscrollarea.h>
+#include <HbScrollArea>
 
 // User includes
 #include "calendaycommonheaders.h"
--- a/calendarui/views/dayview/inc/calendaycontentwidget.h	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/dayview/inc/calendaycontentwidget.h	Wed Aug 25 14:02:13 2010 +0530
@@ -19,7 +19,7 @@
 #define CALENDAYCONTENTWIDGET_H_
 
 // System includes
-#include <hbwidget.h>
+#include <HbWidget>
 
 // User includes
 #include "calendaycommonheaders.h"
@@ -61,8 +61,8 @@
     void relayoutWidgets(CalenScrollDirection scrollTo);
     void widgetScrolled(const QPointF &newPos);
     
-private:
-    void initializeViews(QGraphicsItem *parent);
+protected:
+    void initializeViews();
 
 private:
     QGraphicsLinearLayout* mLayout; //!< Linear layout for day views
--- a/calendarui/views/dayview/inc/calendaystatusstrip.h	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/dayview/inc/calendaystatusstrip.h	Wed Aug 25 14:02:13 2010 +0530
@@ -47,15 +47,11 @@
     
     qreal range() const;
 
-    QColor color() const;
-
     CalenDayStatusStrip::DrawingStyle drawingStyle() const;
     
     QPair<QTime,QTime> startEndTime() const;
     
-    void setRange(qreal mRange);
-
-    void setColor(QColor mStripColor);
+    void setRange(qreal range);
     
     void setDrawingStyle(CalenDayStatusStrip::DrawingStyle mDrawingStyle);
     
@@ -78,7 +74,6 @@
     
 private:
     qreal mRange; //!<Distance between lines
-    QColor mColor;//!<Color of status stripe
     CalenDayStatusStrip::DrawingStyle mDrawingStyle;//!<Specify style of drawing
     /*!
        Original start and end time of event
--- a/calendarui/views/dayview/inc/calendayview.h	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/dayview/inc/calendayview.h	Wed Aug 25 14:02:13 2010 +0530
@@ -32,6 +32,7 @@
 class XQSettingsManager;
 class QVariant;
 class HbGroupBox;
+class HbFrameItem;
 class AgendaEntry;
 class CalenDocLoader;
 class CalenDayContentScrollArea;
@@ -150,6 +151,7 @@
      * Scrolls content to correct position after view repopulation
      */
     void setupViewport();
+    void orientationChanged(Qt::Orientation orientation);
 
 private:
     /**
@@ -175,6 +177,7 @@
     CalenDayContentWidget* mContentWidget;    //!< Content widget
     CalenDayHourScrollArea* mHourScrollArea;  //!< Scroll area for hour elements
     QGraphicsLinearLayout* mVLayout;    //!< Vertical layout for day view
+    HbWidget* mMainContainer;//!< Container widget for hour elements and content
     
     CalenDocLoader* mDocLoader; //!< Document loader for day view
     
@@ -183,7 +186,7 @@
 private:    
 
     XQSettingsManager* mSettingsManager;
-    XQSettingsKey mRegionalInfo;
+    XQSettingsKey mRegionalInfoKey;
     MCalenServices  &mServices;
 	
     /**
@@ -198,6 +201,8 @@
      * \brief It keep pointer to go to Today action from menu. 
      */
     HbAction *mGoToTodayMenuAction;
+    
+    HbFrameItem *mBg;   //!< Background graphic for content and hour elements
 };
 
 
--- a/calendarui/views/dayview/resources/calendayitem.widgetml	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/dayview/resources/calendayitem.widgetml	Wed Aug 25 14:02:13 2010 +0530
@@ -11,8 +11,8 @@
         <meshitem src="colorStripe" srcEdge="LEFT" dst="" dstEdge="LEFT" spacing="-var(hb-param-margin-gene-middle-horizontal)"/>
         <meshitem src="colorStripe" srcEdge="RIGHT" dst="eventDescription" dstEdge="LEFT" spacing="var(hb-param-margin-gene-middle-horizontal)"/>
         
-        <meshitem src="eventDescription" srcEdge="TOP" dst="" dstEdge="TOP" spacing="-var(hb-param-margin-gene-middle-vertical)" />
-        <meshitem src="eventDescription" srcEdge="BOTTOM" dst="" dstEdge="BOTTOM" spacing="var(hb-param-margin-gene-middle-vertical)" />
+        <meshitem src="eventDescription" srcEdge="TOP" dst="" dstEdge="TOP" spacing="-var(hb-param-margin-gene-top)" />
+        <meshitem src="eventDescription" srcEdge="BOTTOM" dst="" dstEdge="BOTTOM" spacing="var(hb-param-margin-gene-bottom)" />
         <meshitem src="eventDescription" srcEdge="RIGHT" dst="" dstEdge="RIGHT" spacing="var(hb-param-margin-gene-right)"/>
     </layout>
 	
@@ -25,7 +25,7 @@
         <meshitem src="colorStripe" srcEdge="TOP" dst="" dstEdge="TOP" />
         <meshitem src="colorStripe" srcEdge="BOTTOM" dst="" dstEdge="BOTTOM" />      
         <meshitem src="colorStripe" srcEdge="LEFT" dst="" dstEdge="LEFT" spacing="-var(hb-param-margin-gene-middle-horizontal)"/>
-        <meshitem src="colorStripe" srcEdge="RIGHT" dst="" dstEdge="RIGHT" spacer="spacerItem"/>
+        <meshitem src="colorStripe" srcEdge="RIGHT" dst="" dstEdge="RIGHT" spacing="var(hb-param-margin-gene-middle-horizontal)"/>
     </layout>
 	
     <layout name="noIconNoTextNoBkgLayout" type="mesh">
--- a/calendarui/views/dayview/src/calendaycontainer.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/dayview/src/calendaycontainer.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -238,12 +238,12 @@
 
     // Event's startX/width
     eventWidth /= columns;
-
-    // In case when eventWidth will be smaller then KCalenMinBubbleWidth [un]
+    
+    // In case when eventWidth will be smaller then KCalenMinEventWidth [un]
     // spacings between events should be smaller.
     // Check whether it's possible to shrink them so the bubbles width 
-    // can stay at KCalenMinBubbleWidth [un] (time stripe + frame margins).
-    qreal minWidth = KCalenMinBubbleWidth * mLayoutValues.unitInPixels;
+    // can stay at KCalenMinEventWidth [un] (time stripe + frame margins).
+    qreal minWidth = KCalenMinEventWidth * mLayoutValues.unitInPixels;
     if (eventWidth - mLayoutValues.eventMargin < minWidth) {
 
         // Calculate new margin value
@@ -267,7 +267,8 @@
             eventWidth = minWidth;
         }
         
-        //First column margin should be always 1.5un (mLayoutValues.eventMargin)
+        // First column margin should be always KCalenSpaceBeetwenEvents 
+        // (mLayoutValues.eventMargin)
         eventStartX += columnIdx * (eventWidth + newMarginValue) + mLayoutValues.eventMargin;
     }
     else {
@@ -277,6 +278,10 @@
     }
 
     QRectF eventGeometry(eventStartX, eventStartY, eventWidth, eventHeight);
+    
+    // Workaround to prevent size hint caching inside effectiveSizeHint
+    item->setMinimumSize(0, 0);
+    item->setMaximumSize(eventWidth, eventHeight);
     item->setGeometry(eventGeometry);
 }
 
@@ -341,6 +346,10 @@
     }
 
     QRectF eventGeometry(eventStartX, eventStartY, eventWidth, eventHeight);
+	
+    // Workaround to prevent size hint caching inside effectiveSizeHint
+    item->setMinimumSize(0, 0);
+    item->setMaximumSize(eventWidth, eventHeight);
     item->setGeometry(eventGeometry);
 }
 
@@ -367,8 +376,7 @@
     }
 
     // 2. event area width -> eventAreaWidth[out]
-    qreal emptyRightColumnWidth(0.0);
-    emptyRightColumnWidth = KCalenEmptyRightColumnWidth
+    qreal emptyRightColumnWidth = KCalenEmptyRightColumnWidth
         * layoutValues.unitInPixels;
     layoutValues.eventAreaWidth = contentWidth - emptyRightColumnWidth
         - layoutValues.eventAreaX;
@@ -383,7 +391,8 @@
 
     // check if we should create absorber over some overlapping region
     layoutValues.maxColumns = layoutValues.eventAreaWidth
-        / (KCalenMinTouchableEventWidth * layoutValues.unitInPixels);
+        / ((KCalenMinTouchableEventWidth + KCalenSpaceBeetwenEvents)
+            * layoutValues.unitInPixels);
 }
 
 
--- a/calendarui/views/dayview/src/calendaycontentscrollarea.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/dayview/src/calendaycontentscrollarea.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -19,8 +19,8 @@
 #include <QGraphicsLinearLayout>
 #include <QGesture>
 
-#include <hbinstance.h>
-#include <hbswipegesture.h>
+#include <HbInstance>
+#include <HbSwipeGesture>
 
 // User includes
 #include "calendaycontentscrollarea.h"
--- a/calendarui/views/dayview/src/calendaycontentwidget.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/dayview/src/calendaycontentwidget.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -17,7 +17,7 @@
 
 // System includes
 #include <QGraphicsLinearLayout>
-#include <hbmodeliterator.h>
+#include <HbModelIterator>
 
 // User includes
 #include "calendaymodelmanager.h"
@@ -33,6 +33,7 @@
 /*!
  \brief Constructor
  
+ \param modelManager Day View model manager
  \param parent The parent of central widget
  */
 CalenDayContentWidget::CalenDayContentWidget(
@@ -41,7 +42,7 @@
     HbWidget(parent), mLayout(NULL), mModelManager(modelManager)
 {
     mWidgets.clear();
-    initializeViews(parent);
+    initializeViews();
 }
 
 /*!
@@ -198,7 +199,7 @@
  
  \param parent Parent object 
  */
-void CalenDayContentWidget::initializeViews(QGraphicsItem *parent)
+void CalenDayContentWidget::initializeViews()
 {
     // Create item views
     HbModelIterator *iterator(0);
@@ -227,12 +228,14 @@
     connect(nextItemView, SIGNAL(scrollPositionChanged(const QPointF&)), this,
         SLOT(widgetScrolled(const QPointF&)));
 
-    // Install event filters to receive events necessary for gesture handling
-    CalenDayContentScrollArea* scrollArea =
-        static_cast<CalenDayContentScrollArea*> (parent);
-    prevItemView->installEventFilter(scrollArea);
-    currItemView->installEventFilter(scrollArea);
-    nextItemView->installEventFilter(scrollArea);
+    if (parentItem()) {
+        // Install event filters to receive events necessary for gesture handling
+        CalenDayContentScrollArea* scrollArea =
+            static_cast<CalenDayContentScrollArea*> (parentItem());
+        prevItemView->installEventFilter(scrollArea);
+        currItemView->installEventFilter(scrollArea);
+        nextItemView->installEventFilter(scrollArea);
+    }
 
     // Add views to layout
     add(prevItemView);
--- a/calendarui/views/dayview/src/calendayeventspane.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/dayview/src/calendayeventspane.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -16,10 +16,11 @@
 */
 // System includes
 #include <QPainter>
-#include <hbcolorscheme.h>
+#include <HbColorScheme>
 
 // User includes
-#include "CalenDayEventsPane.h"
+#include "calendayeventspane.h"
+#include "calendaycommonheaders.h"
 
 /*!
  \class CalenDayEventsPane
@@ -39,12 +40,13 @@
 
     HbDeviceProfile deviceProfile;
     mUnitInPixels = deviceProfile.unitValue();
-    mHourLineColor = HbColorScheme::color("qtc_cal_day_hour_lines");
+    mHourLineColor = HbColorScheme::color(KCalenHourLineColor);
     
     // Set custom dashed pen
-    mCustomDashedPen.setWidth(0.15);
+    mCustomDashedPen.setWidth(KCalenHourLineThickness);
     QVector<qreal> dashes;
-    dashes << 5 << 5;
+    dashes << KCalenHalfHourLineDashWidth * mUnitInPixels 
+        << KCalenHalfHourLineDashWidth * mUnitInPixels;
     mCustomDashedPen.setDashPattern(dashes);
     mCustomDashedPen.setCapStyle(Qt::FlatCap);
     mCustomDashedPen.setColor(mHourLineColor);
@@ -89,7 +91,7 @@
     
     QRectF drawArea = option->rect;
     
-    const qreal hourLineThickness = 0.15; //un (according to UI spec)
+    const qreal hourLineThickness = KCalenHourLineThickness;
 
     painter->save();
     
--- a/calendarui/views/dayview/src/calendayhourelement.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/dayview/src/calendayhourelement.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -141,8 +141,8 @@
                 * currentDateTime.time().minute() / 60;
 
             QColor color = HbColorScheme::color(KCalenTimeLineColor);
-            painter->setPen(QPen(color, KCalenTimeLineThickness * mUnitInPixels,
-                Qt::SolidLine, Qt::FlatCap));
+            painter->setPen(QPen(color, KCalenCurrentTimeLineThickness
+                * mUnitInPixels, Qt::SolidLine, Qt::FlatCap));
             QLineF currentTimeline(drawArea.left(), drawArea.top() + currentTimeY,
                     drawArea.right(), drawArea.top() + currentTimeY);
             painter->drawLine(currentTimeline);
--- a/calendarui/views/dayview/src/calendayitem.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/dayview/src/calendayitem.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -16,15 +16,15 @@
 *
 */
 
-//System includes
-#include <hbframeitem.h>
-#include <hbtextitem.h>
+// System includes
+#include <HbFrameItem>
+#include <HbTextItem>
+#include <HbStyle>
+#include <HbColorScheme>
 #include <agendaentry.h>
-#include <hbstyle.h>
-#include <hbcolorscheme.h>
 
-
-//User inlcudes
+// User includes
+#include "calendaycommonheaders.h"
 #include "calendayitem.h"
 #include "calendaystatusstrip.h"
 #include "calendaymodel.h"
@@ -33,69 +33,61 @@
 #include "calendaycontainer.h"
 
 /*!
-   \brief Constructor.
-*/
-CalenDayItem::CalenDayItem(const CalenDayContainer *container):
-    mContainer(container), mUpdated(false), mBg(0), mEventDesc(0), mColorStripe(0), 
-    mEventDescMinWidth(0.0), mFrameMinWidth(0.0)
+ \brief Constructor.
+ */
+CalenDayItem::CalenDayItem(const CalenDayContainer *container) :
+    mContainer(container), mUpdated(false), mBg(0), mEventDesc(0),
+        mColorStripe(0), mEventDescMinWidth(0.0), mFrameMinWidth(0.0)
 {
 }
 
 /*!
-   \brief Constructor.
-*/
+ \brief Constructor.
+ */
 CalenDayItem::CalenDayItem(const CalenDayItem & source) :
-    HbAbstractViewItem(source), mContainer(source.container()), mUpdated(false), mBg(0), mEventDesc(0), 
-    mColorStripe(0), mEventDescMinWidth(0.0), mFrameMinWidth(0.0)
+    HbAbstractViewItem(source), mContainer(source.container()),
+        mUpdated(false), mBg(0), mEventDesc(0), mColorStripe(0),
+        mEventDescMinWidth(0.0), mFrameMinWidth(0.0)
 {
-    // TODO: "qtg_fr_btn_pressed" need to replaced with qtg_fr_cal_meeting_bg
-	// when available
-    mBg = new HbFrameItem("qtg_fr_btn_pressed", HbFrameDrawer::NinePieces, this);
+    mBg = new HbFrameItem("qtg_fr_cal_meeting_bg", HbFrameDrawer::NinePieces,
+        this);
     mEventDesc = new HbTextItem(this);
     // TODO: probably ElideLeft needed for mirrored layout
     mEventDesc->setElideMode(Qt::ElideRight);
     mEventDesc->setTextWrapping(Hb::TextWrapAnywhere);
-    
     mColorStripe = new CalenDayStatusStrip(this);
-    
+
     HbStyle::setItemName(mBg, QLatin1String("backgroundFrame"));
     HbStyle::setItemName(mEventDesc, QLatin1String("eventDescription"));
-    HbStyle::setItemName(static_cast<QGraphicsItem *>(mColorStripe), QLatin1String("colorStripe"));
-    
+    HbStyle::setItemName(static_cast<QGraphicsItem *> (mColorStripe),
+        QLatin1String("colorStripe"));
+
     HbDeviceProfile deviceProfile;
-    HbStyle style;
-    
-    qreal horizontalSpacing = 0.0;
-    qreal rightMargin = 0.0;
-    
-    style.parameter(QString("hb-param-margin-gene-middle-horizontal"), 
-        horizontalSpacing, deviceProfile);
-    style.parameter(QString("hb-param-margin-gene-right"), 
-        rightMargin, deviceProfile); 
-    
-    qreal stripeWidth = 1.5 * deviceProfile.unitValue(); //1.5un according to UI spec
-    
-    mFrameMinWidth = 2 * horizontalSpacing + stripeWidth; //smallest width for which background frame is displayed
-    mEventDescMinWidth = mFrameMinWidth + rightMargin;//smallest width for which text can be displayed
-    
-    //Minimum width is assured by widgetml and css
-    //additionally called here to prevent minimum size hint caching inside effectiveSizeHint
+    qreal stripeWidth = KCalenTimeStripWidth * deviceProfile.unitValue();
+    mColorStripe->setPreferredWidth(stripeWidth);
+
+    // Minimum size of event frame (without/with description) 
+    mFrameMinWidth = KCalenMinEventWidth * deviceProfile.unitValue();
+    mEventDescMinWidth = KCalenMinTouchableEventWidth
+        * deviceProfile.unitValue();
+
+    // Minimum width is assured by widgetml and css, additionally called here 
+    // to prevent minimum size hint caching inside effectiveSizeHint
     setMinimumWidth(stripeWidth);
-
 }
 
 /*!
-   \brief Destructor.
-*/
+ \brief Destructor.
+ */
 CalenDayItem::~CalenDayItem()
 {
 }
 
 /*!
-   \brief Creates new instance of day item.
-   
-   \return New instance of day item.
-*/
+ \brief Creates new instance of day item.
+ 
+ \return New instance of day item.
+ */
 HbAbstractViewItem * CalenDayItem::createItem()
 {
     CalenDayItem* newItem = new CalenDayItem(*this);
@@ -104,17 +96,16 @@
 
 
 /*!
-   \brief Sets data to be displayed on item.
-*/
+ \brief Sets data to be displayed on item.
+ */
 void CalenDayItem::updateChildItems()
 {
     // there is no need to update items after creation
     if (!mUpdated) {
         AgendaEntry entry;
-        entry = modelIndex().data(CalenDayEntry).value<AgendaEntry>();
+        entry = modelIndex().data(CalenDayEntry).value<AgendaEntry> ();
 
-		bool isAllDayEvent = CalenAgendaUtils::isAlldayEvent(entry); 
-
+        bool isAllDayEvent = CalenAgendaUtils::isAlldayEvent(entry);
         setDescription(entry, isAllDayEvent);
         setStatusStrip(entry, isAllDayEvent);
 
@@ -128,62 +119,53 @@
 
 
 /*!
-   \brief Adds event description for the item.
-   
-   \param entry An for which description needs to be displayed.
-   \param allDayEvent Flag that indicates whether an item is all day event
-*/
+ \brief Adds event description for the item.
+ 
+ \param entry An for which description needs to be displayed.
+ \param allDayEvent Flag that indicates whether an item is all day event
+ */
 void CalenDayItem::setDescription(const AgendaEntry &entry, bool allDayEvent)
 {
-	QString description(entry.summary());
-	QString location(entry.location());
-	
-	
-	int separtorPos = 0;
-	
-	if(!location.isEmpty()) {
-	    if ( !description.isEmpty() ) {
-	    	separtorPos = description.count();
-	    	description.append(", ");
-			}
-	    
-		description.append(location);
-		}
-	
-	if ( description.isEmpty() ) {
-	    description.append(hbTrId("txt_calendar_dblist_unnamed"));
-	}
-	
-	//Description of all day events has to be displayed vertically
-	if(allDayEvent){
+    QString description(entry.summary());
+    QString location(entry.location());
+
+    int separtorPos = 0;
+    if (!location.isEmpty()) {
+        if (!description.isEmpty()) {
+            separtorPos = description.count();
+            description.append(", ");
+        }
+        description.append(location);
+    }
+
+    if (description.isEmpty()) {
+        description.append(hbTrId("txt_calendar_dblist_unnamed"));
+    }
 
-	    QString verticalString;
-	    for(int i=0; i<description.count(); i++){
-	    
-	        verticalString.append(QString(description.at(i)) + "\n");
-	    }
-	
-	    // remove "\n" before comma separator if exist
-	    if (separtorPos)
-	    	{
-	    	verticalString.remove( 2*separtorPos-1, 1);
-	    	}
-	    description = verticalString;
-	}	
-	
-	mEventDesc->setText(description);
+    //Description of all day events has to be displayed vertically
+    if (allDayEvent) {
+        QString verticalString;
+        for (int i = 0; i < description.count(); i++) {
+            verticalString.append(QString(description.at(i)) + "\n");
+        }
+
+        // remove "\n" before comma separator if exist
+        if (separtorPos) {
+            verticalString.remove(2 * separtorPos - 1, 1);
+        }
+        description = verticalString;
+    }
+
+    mEventDesc->setText(description);
 }
 
 /*!
-   \brief It set all needed things for status strip from Agenda Entry.
-   
-   \param entry Status Strip is created from Agenda Entry
-*/
+ \brief It set all needed things for status strip from Agenda Entry.
+ 
+ \param entry Status Strip is created from Agenda Entry
+ */
 void CalenDayItem::setStatusStrip(const AgendaEntry &entry, bool allDayEvent)
 {
-    QColor color = HbColorScheme::color("qtc_cal_month_current_day");
-    mColorStripe->setColor(color);
-    
     if (!allDayEvent) {
 
         QDateTime startTime;
@@ -191,8 +173,8 @@
         QDateTime currentDateTime;
         currentDateTime.setDate(container()->date());
 
-        CalenDayUtils::instance()->getEventValidStartEndTime(startTime, endTime, entry,
-            currentDateTime);
+        CalenDayUtils::instance()->getEventValidStartEndTime(startTime,
+            endTime, entry, currentDateTime);
 
         mColorStripe->setStartEndTime(startTime.time(), endTime.time());
     }
@@ -202,49 +184,52 @@
         // 00:00:00 and 00:00:00 next day respectively.
         // To draw it correctly we need times like those visible for user in
         // editor: 00:00:00 to 23:59:59 (the same day)
-        mColorStripe->setStartEndTime(entry.startTime().time(), entry.endTime().time().addSecs(-1));
+        mColorStripe->setStartEndTime(entry.startTime().time(),
+            entry.endTime().time().addSecs(-1));
     }
-    
+
     switch (entry.status()) {
         case AgendaEntry::Confirmed:
             mColorStripe->setDrawingStyle(CalenDayStatusStrip::Filled);
-        break;
+            break;
         case AgendaEntry::Tentative:
             mColorStripe->setDrawingStyle(CalenDayStatusStrip::StripWithLines);
-        break;
+            break;
         case AgendaEntry::Cancelled:
             mColorStripe->setDrawingStyle(CalenDayStatusStrip::OnlyFrame);
-        break;
+            break;
         default:
             mColorStripe->setDrawingStyle(CalenDayStatusStrip::Filled);
-        break;
+            break;
     }
 }
 
 /*!
-   \brief Reimplemented from HbWidget. Handles resize event.
-   
-   \param event Instance of an event to be handled.
-*/
+ \brief Reimplemented from HbWidget. Handles resize event.
+ 
+ \param event Instance of an event to be handled.
+ */
 void CalenDayItem::resizeEvent(QGraphicsSceneResizeEvent *event)
 {
     Q_UNUSED(event)
 
     qreal width = rect().width();
 
-    if(width < mEventDescMinWidth){
+    if (width < mEventDescMinWidth) {
         mEventDesc->hide();
-    } else{
+    }
+    else {
         mEventDesc->show();
     }
-        
-    if(width < mFrameMinWidth){
+
+    if (width < mFrameMinWidth) {
         mBg->hide();
-    } else{
+    }
+    else {
         mBg->show();
     }
 
-    //Necessary to switch layout
+    // Necessary to switch layout
     repolish();
 }
 
--- a/calendarui/views/dayview/src/calendayitemview.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/dayview/src/calendayitemview.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -18,9 +18,9 @@
 //System includes
 #include <QGesture>
 #include <QGraphicsLinearLayout>
-#include <hbabstractviewitem.h>
-#include <hbinstance.h>
-#include <hbaction.h>
+#include <HbAbstractViewItem>
+#include <HbInstance>
+#include <HbAction>
 
 //User includes
 #include "calendayitemview.h"
@@ -55,9 +55,6 @@
     setScrollingStyle(HbScrollArea::PanWithFollowOn);
     setVerticalScrollBarPolicy(HbScrollArea::ScrollBarAlwaysOff);
     
-    grabGesture(Qt::PanGesture);
-    ungrabGesture(Qt::SwipeGesture);
-    
     //TODO: KG: Animate item pressed?! HbAbstractItemView::TouchDown
     setEnabledAnimations( HbAbstractItemView::None );
     
--- a/calendarui/views/dayview/src/calendaymodelmanager.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/dayview/src/calendaymodelmanager.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -15,9 +15,11 @@
 *
 */
 
+// System includes
 #include <calenservices.h>
 #include <calencontext.h>
 
+// User includes
 #include "calendaymodelmanager.h"
 #include "calendaymodel.h"
 
--- a/calendarui/views/dayview/src/calendaystatusstrip.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/dayview/src/calendaystatusstrip.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -15,11 +15,15 @@
  *
  */
 
+// System includes
 #include <QPainter>
 #include <QPen>
+#include <HbColorScheme>
 
+// User includes
 #include "calendaystatusstrip.h"
 
+// Constants
 qreal const CalenDayStatusStrip::mMinute = 60;
 qreal const CalenDayStatusStrip::mMinimumTime = 5;
 
@@ -28,7 +32,7 @@
  */
 CalenDayStatusStrip::CalenDayStatusStrip(HbWidget *parent)
     : HbWidget(parent), mRange(2), 
-      mDrawingStyle(CalenDayStatusStrip::Filled)      
+      mDrawingStyle(CalenDayStatusStrip::Filled)
 {
     setFlag(QGraphicsItem::ItemHasNoContents,false);
 
@@ -54,16 +58,6 @@
 }
 
 /*!
-   \brief Returns color drawing
-   
-   \sa setColor
- */
-QColor CalenDayStatusStrip::color() const
-{
-    return mColor;
-}
-
-/*!
    \brief Returns style of drawing.
    
    \sa CalenDayStatusStrip::DrawingStyle, setDrawingStyle
@@ -97,18 +91,6 @@
 }
 
 /*!
-   \brief It sets color drawing
-   
-   \param stripColor Color of drawing
-   
-   \sa stripColor
- */
-void CalenDayStatusStrip::setColor(QColor stripColor)
-{
-    mColor = stripColor;
-}
-
-/*!
    \brief It sets drawing style of strip 
    
    \param drawingStyle Style of strip drawing.
@@ -193,7 +175,7 @@
     painter->setClipRect(bounding, Qt::IntersectClip);
 
     //prepare brush and paint
-    QBrush brush(mColor);
+    QBrush brush(HbColorScheme::color("qtc_cal_month_current_day"));
     painter->setBrush(brush);
     QPen pen;
     pen.setWidth(1);
--- a/calendarui/views/dayview/src/calendayutils.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/dayview/src/calendayutils.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -16,10 +16,10 @@
 */
 
 // System includes
-#include <hbdeviceprofile.h>
-#include <hbstyle.h>
-#include <hbinstance.h>
-#include <qdatetime.h>
+#include <QDateTime>
+#include <HbDeviceProfile>
+#include <HbStyle>
+#include <HbInstance>
 
 // User includes
 #include "calendayutils.h"
--- a/calendarui/views/dayview/src/calendayview.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/dayview/src/calendayview.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -20,13 +20,15 @@
 #include <QGraphicsLinearLayout>
 #include <xqsettingsmanager.h>
 #include <HbWidget>
-#include <hbaction.h>
-#include <hbmenu.h>
-#include <hbmainwindow.h>
-#include <hbmodeliterator.h>
-#include <hbstyleloader.h>
-#include <hbgroupbox.h>
-#include <hbextendedlocale.h>
+#include <HbFrameItem>
+#include <HbInstance>
+#include <HbAction>
+#include <HbMenu>
+#include <HbMainWindow>
+#include <HbModelIterator>
+#include <HbStyleLoader>
+#include <HbGroupBox>
+#include <HbExtendedLocale>
 #include <agendautil.h>
 
 // User includes
@@ -44,6 +46,7 @@
 #include "CalendarPrivateCRKeys.h"
 #include "calenpluginlabel.h"
 #include "calendaymodel.h"
+#include "calendayutils.h"
 
 //constants
 
@@ -53,18 +56,18 @@
 */
 CalenDayView::CalenDayView(MCalenServices &services) :
     CalenNativeView(services), mContentScrollArea(NULL), mContentWidget(NULL),
-        mHourScrollArea(NULL), mVLayout(NULL), mDocLoader(NULL), mIsLaunching(
-            true), mSettingsManager(NULL), mRegionalInfo(
-            XQSettingsKey::TargetCentralRepository, KCRUidCalendar,
-            KCalendarShowRegionalInfo), mServices(services),
-        mRegionalInfoGroupBox(NULL), mGoToTodayMenuAction(NULL)
+        mHourScrollArea(NULL), mVLayout(NULL), mMainContainer(NULL),
+        mDocLoader(NULL), mIsLaunching(true), mSettingsManager(NULL),
+        mRegionalInfoKey(XQSettingsKey::TargetCentralRepository,
+            KCRUidCalendar, KCalendarShowRegionalInfo), mServices(services),
+        mRegionalInfoGroupBox(NULL), mGoToTodayMenuAction(NULL), mBg(NULL)
 {
     setupMenu();
 
     // Create model manager
     mModelManager = new CalenDayModelManager(mServices, true, this);
     mSettingsManager = new XQSettingsManager(this);
-    mSettingsManager->startMonitoring(mRegionalInfo);
+    mSettingsManager->startMonitoring(mRegionalInfoKey);
 
     //setup Back functionality
     if (ECalenDayView != mServices.getFirstView()) {
@@ -87,7 +90,13 @@
 */
 CalenDayView::~CalenDayView()
 {
-    mSettingsManager->stopMonitoring(mRegionalInfo);
+    mSettingsManager->stopMonitoring(mRegionalInfoKey);
+    
+    if (mRegionalInfoGroupBox) {
+        delete mRegionalInfoGroupBox;
+        mRegionalInfoGroupBox = NULL;
+    }
+    
     if (mDocLoader) {
         delete mDocLoader;
         mDocLoader = NULL;
@@ -175,6 +184,19 @@
         CALEN_DAYVIEW_DAYINFO));
     HbEffect::add(mHeadingLabel, ":/fade_out.fxml", "fadeOut");
     HbEffect::add(mHeadingLabel, ":/fade_in.fxml", "fadeIn");
+    
+    // Set up main container for hour elements/content area
+    mMainContainer = qobject_cast<HbWidget *> (mDocLoader->findWidget(
+        CALEN_DAYVIEW_CONTENTWIDGET));
+    if (Qt::Vertical == CalenDayUtils::instance()->orientation()) {
+        mBg = new HbFrameItem(KCalenBackgroundColorPortrait,
+            HbFrameDrawer::OnePiece, this);
+    }
+    else {
+        mBg = new HbFrameItem(KCalenBackgroundColorLandscape,
+            HbFrameDrawer::OnePiece, this);
+    }
+    mMainContainer->setBackgroundItem(mBg);
 
     // Set up hour scroll area
     mHourScrollArea
@@ -185,13 +207,14 @@
     mContentScrollArea
         = static_cast<CalenDayContentScrollArea *> (mDocLoader->findWidget(
             CALEN_DAYVIEW_CONTENTSCROLLAREA));
-    mContentWidget = new CalenDayContentWidget(*mModelManager, NULL);
+    // Pass parent object to mContentWidget to install event filters on parent
+    mContentWidget = new CalenDayContentWidget(*mModelManager, mContentScrollArea);
     mContentScrollArea->setContentWidget(mContentWidget);
 
+    setupSlots();
+    
     // Set up regional info if variant is correct
     showRegionalInformationFadeIn();
-
-    setupSlots();
 }
 
 //private slots
@@ -229,7 +252,10 @@
     
     // Triggers fading effect for heading label.
     HbEffect::start(mHeadingLabel, "fadeOut", this, "setHeadingText");
-    HbEffect::start(mRegionalInfoGroupBox, "fadeOut", this, "showRegionalInformation");
+    if (mRegionalInfoGroupBox) {
+        HbEffect::start(mRegionalInfoGroupBox, "fadeOut", this,
+            "showRegionalInformation");
+    }
     
     mServices.Context().setFocusDate(mDate);
 }
@@ -314,10 +340,14 @@
 
     connect(mContentWidget, SIGNAL(scrollPositionChanged(const QPointF &)),
         mHourScrollArea, SLOT(scrollVertically(const QPointF &)));
-    
+
     connect(mHourScrollArea, SIGNAL(scrollPositionChanged(const QPointF &)),
         mContentWidget, SLOT(widgetScrolled(const QPointF &)));
-    
+
+    connect(CalenDayUtils::instance()->mainWindow(),
+        SIGNAL(orientationChanged(Qt::Orientation)), this,
+        SLOT(orientationChanged(Qt::Orientation)));
+
     connect(mSettingsManager, SIGNAL(valueChanged(XQSettingsKey, QVariant)),
         this, SLOT(showHideRegionalInformationChanged(XQSettingsKey, QVariant)));
 }
@@ -400,8 +430,10 @@
 */
 void CalenDayView::showRegionalInformationFadeIn()
 {
-	showHideRegionalInformationChanged(mRegionalInfo, 3);
-	HbEffect::start(mRegionalInfoGroupBox, "fadeIn");
+	showHideRegionalInformationChanged(mRegionalInfoKey, 3);
+	if (mRegionalInfoGroupBox) {
+	    HbEffect::start(mRegionalInfoGroupBox, "fadeIn");
+	}
 }
 
 /*!
@@ -411,34 +443,41 @@
     const XQSettingsKey& key,
     const QVariant&)
 {
-    if (key.key() == mRegionalInfo.key()) {
+    if ((key.key() == mRegionalInfoKey.key()) && pluginEnabled()) {
         int showRegionalInfo =
-            mSettingsManager->readItemValue(mRegionalInfo).toUInt();
+            mSettingsManager->readItemValue(mRegionalInfoKey).toUInt();
+        if (showRegionalInfo) {
+            if (!mRegionalInfoGroupBox) {
+                mRegionalInfoGroupBox = new HbGroupBox();
+                CalenPluginLabel *regionalInfo = new CalenPluginLabel(
+                    mServices, this);
+                regionalInfo->setFontSpec(HbFontSpec(HbFontSpec::Primary));
 
-        if (showRegionalInfo) {
+                // Set margins in groupbox according to UI spec
+                HbStyle style;
+                HbDeviceProfile deviceProfile;
+                qreal leftMargin = 0.0;
+                qreal rightMargin = 0.0;
+                qreal topMargin = 0.0;
+                qreal bottomMargin = 0.0;
+                style.parameter(QString("hb-param-margin-gene-left"),
+                    leftMargin, deviceProfile);
+                style.parameter(QString("hb-param-margin-gene-right"),
+                    rightMargin, deviceProfile);
+                style.parameter(QString("hb-param-margin-gene-top"), topMargin,
+                    deviceProfile);
+                style.parameter(QString("hb-param-margin-gene-bottom"),
+                    bottomMargin, deviceProfile);
+                regionalInfo->setContentsMargins(leftMargin, topMargin,
+                    rightMargin, bottomMargin);
+                mRegionalInfoGroupBox->setContentWidget(regionalInfo);
+
+                mVLayout->insertItem(1, mRegionalInfoGroupBox);
+            }
             QString *pluginString = pluginText();
-            if (pluginString) {
-                if (!mRegionalInfoGroupBox) {
-                    mRegionalInfoGroupBox = qobject_cast<HbGroupBox *> (
-                        mDocLoader->findWidget(CALEN_DAYVIEW_REGIONALINFO));
-                    CalenPluginLabel *regionalInfo = new CalenPluginLabel(
-                        mServices, this);
-                    HbEffect::add(mRegionalInfoGroupBox, ":/fade_out.fxml",
-                        "fadeOut");
-                    HbEffect::add(mRegionalInfoGroupBox, ":/fade_in.fxml",
-                        "fadeIn");
-                    regionalInfo->setContentsMargins(1, 1, 1, 1);
-                    mRegionalInfoGroupBox->setContentWidget(regionalInfo);
-                }
-
-                if (pluginEnabled()) {
-                    HbLabel *pluginInfoLabel = qobject_cast<HbLabel *> (
-                        mRegionalInfoGroupBox->contentWidget());
-
-                    pluginInfoLabel->setPlainText(*pluginString);
-                    mVLayout->insertItem(1, mRegionalInfoGroupBox);
-                }
-            }
+            HbLabel *pluginInfoLabel = qobject_cast<HbLabel *> (
+                mRegionalInfoGroupBox->contentWidget());
+            pluginInfoLabel->setPlainText(*pluginString);
         }
         else {
             if (mRegionalInfoGroupBox) {
@@ -483,4 +522,24 @@
     }
 }
 
+/*!
+ \brief Slot which is called whenever the orientation of the device changes.
+ 
+ Changes the backgroung graphic element when orientation chandes.
+ 
+ \param orientation Current device orientation
+ */
+void CalenDayView::orientationChanged(Qt::Orientation orientation)
+{
+    if (Qt::Vertical == orientation) {
+        mBg = new HbFrameItem(KCalenBackgroundColorPortrait,
+            HbFrameDrawer::OnePiece, this);
+    }
+    else {
+        mBg = new HbFrameItem(KCalenBackgroundColorLandscape,
+            HbFrameDrawer::OnePiece, this);
+    }
+    mMainContainer->setBackgroundItem(mBg);
+}
+
 //End of File
--- a/calendarui/views/dayview/tsrc/unittests/unittest_calendaystatusstrip/unittest_calendaystatusstrip.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/dayview/tsrc/unittests/unittest_calendaystatusstrip/unittest_calendaystatusstrip.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -42,7 +42,6 @@
     void cleanup();
 
     void testConstructors();
-    void testSetGetColor();
     void testSetGetRange();
     void testSetGetDrawingStyle_data();
     void testSetGetDrawingStyle();
@@ -129,24 +128,6 @@
 }
 
 /*!
-   Test function for geting and setting color
-   1. Test setting red color
-   2. Test change color to blue
- */
-void TestCalenStatusStrip::testSetGetColor()
-{
-    //1)
-    mStatusStrip->setColor(QColor(Qt::red));
-    QColor testColor = mStatusStrip->color();
-    QCOMPARE(QColor(Qt::red),testColor);
-    
-    //2)
-    mStatusStrip->setColor(QColor(Qt::blue));
-    testColor = mStatusStrip->color();
-    QCOMPARE(QColor(Qt::blue),testColor);
-}
-
-/*!
    Test function for geting and setting range
    1. Test setting 5px range
    2. Test change range to 1px
@@ -339,7 +320,6 @@
 void TestCalenStatusStrip::testPaint()
 {      
     //preapre data needed to draw on widget
-    mStatusStrip->setColor(QColor(Qt::red));
     QPair<QTime, QTime> startEndTime;
     startEndTime.first = QTime(10,20,0);
     startEndTime.second = QTime(15,10,00);
--- a/calendarui/views/dayview/tsrc/unittests/unittest_calendayview/calendayutils.h	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/dayview/tsrc/unittests/unittest_calendayview/calendayutils.h	Wed Aug 25 14:02:13 2010 +0530
@@ -47,7 +47,7 @@
 
 	Qt::Orientation orientation()
 		{
-		return 1;
+		return Qt::Horizontal;
 		}
 
 	HbMainWindow* mainWindow()
--- a/calendarui/views/eabi/calenviewsu.def	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/eabi/calenviewsu.def	Wed Aug 25 14:02:13 2010 +0530
@@ -260,4 +260,11 @@
 	_ZThn8_N22CalenDayHourScrollAreaD1Ev @ 259 NONAME
 	_ZThn8_N25CalenDayContentScrollAreaD0Ev @ 260 NONAME
 	_ZThn8_N25CalenDayContentScrollAreaD1Ev @ 261 NONAME
+	_ZN14CalenMonthGrid17handleThemeChangeEv @ 262 NONAME
+	_ZN14CalenMonthView17handleThemeChangeEv @ 263 NONAME
+	_ZN16CalenPreviewPane13effectStartedEv @ 264 NONAME
+	_ZN16CalenPreviewPane14effectFinishedEv @ 265 NONAME
+	_ZN21CalenThickLinesDrawer17handleThemeChangeEv @ 266 NONAME
+	_ZN16CalenPreviewPane17handleThemeChangeEv @ 267 NONAME
+	_ZNK25CalenDayContentScrollArea17isHorizontalSwipeEf @ 268 NONAME
 
--- a/calendarui/views/inc/calengriditemprototype.h	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/inc/calengriditemprototype.h	Wed Aug 25 14:02:13 2010 +0530
@@ -32,15 +32,13 @@
 
 // CONSTANTS
 const QString focusIconName = "qtg_fr_cal_focused_day_ind";
-const QString eventIndname = "qtg_graf_cal_event_ind";
+const QString eventIndname = ":/qtg_graf_cal_event_ind.svg";
 
 class CalenGridItemPrototype : public HbGridViewItem
 {
 	Q_OBJECT
 
 public:
-	CalenGridItemPrototype(QColor todayIndColor, QColor activeColor, QColor inActiveColor, 
-	                       QGraphicsWidget *parent = 0);
 	CalenGridItemPrototype(QGraphicsWidget *parent = 0);
 	virtual ~CalenGridItemPrototype()
 	{
@@ -54,12 +52,14 @@
 	bool canSetModelIndex(const QModelIndex& index);
 	void createPrimitives();
 
+public slots:
+
+	void handleThemeChange();
+
 private:
-	QColor mTodayUnderLineColor;
 	QColor mActiveTextColor;
 	QColor mInActiveTextColor;
 	QColor mCurrentDateColor;
-	QColor mGridBorderColor;
 	HbIconItem *mEventIndicatorItem;
 	HbTextItem *mMonthDayInfoItem;
 	HbFrameItem *mFocusIndicatorItem;
--- a/calendarui/views/inc/calenmonthgrid.h	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/inc/calenmonthgrid.h	Wed Aug 25 14:02:13 2010 +0530
@@ -87,6 +87,10 @@
 	void appendRows();
 	void itemActivated(const QModelIndex &index);
 
+private slots:
+
+	void handleThemeChange();
+	
 private:
 	QStandardItemModel *mModel;
 	scrollDirection mDirection;
@@ -95,14 +99,13 @@
 	CalenMonthView *mView;
 	int mCurrentRow;
 	bool mIsNonActiveDayFocused;
-	QDateTime mNonActiveFocusedDay;
 	bool mIgnoreItemActivated;
 	QPointF mPressedPos;
-	QColor mGridLineColor;
-	QColor mGridBorderColor;
 	QGraphicsWidget* mContentWidget;
 	QList<QString> mLocalisedDates;
 	QPointF mStartPos;
+	QColor mGridLineColor;
+	bool mActiveDatesSet;
 };
 
 #endif // CALENMONTHGRID_H
--- a/calendarui/views/inc/calenmonthview.h	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/inc/calenmonthview.h	Wed Aug 25 14:02:13 2010 +0530
@@ -86,6 +86,7 @@
 	QDateTime firstDayOfGrid();
 	void fetchEntriesAndUpdateModel();
 	void launchDayView();
+	void disconnectAboutToQuitEvent();
 	
 private:
 	void createGrid();
@@ -116,6 +117,7 @@
 	void handleRightEffectCompleted(const HbEffect::EffectStatus &status);
 	void addRemoveActionsInMenu();
 	void changeOrientation(Qt::Orientation orientation);
+	void handleThemeChange();
 	
 private:
 	bool mIsFirstTimeLoad;
@@ -175,6 +177,7 @@
 	HbMenu *mDeleteSubMenu;
 	QColor mWeekDaysColor;
 	bool   mIsAboutToQuitEventConnected; // bool to check if month view is registered to get aboutToQuit signals
+	QColor mPreviewHeadingColor;
 };
 
 #endif //CALENMONTHVIEW_H
--- a/calendarui/views/inc/calenpreviewpane.h	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/inc/calenpreviewpane.h	Wed Aug 25 14:02:13 2010 +0530
@@ -64,6 +64,7 @@
 public slots:
 	void onTwoSecondsTimeout();
 	void scrollingFinished();
+	void handleThemeChange();
     
 private:
 	enum scrollDirection{
@@ -86,6 +87,7 @@
 	bool mIsGestureHandled;
 	qreal mHtDiff;
 	int mScrollDuration;
+	QColor mPreviewTextColor;
 };
 
 #endif /* CALENPREVIEWPANE_H_ */
--- a/calendarui/views/inc/calenthicklinesdrawer.h	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/inc/calenthicklinesdrawer.h	Wed Aug 25 14:02:13 2010 +0530
@@ -37,7 +37,10 @@
 	CalenThickLinesDrawer( CalendarNamespace::WidgetType type, 
 						   QGraphicsItem* parent = NULL );  
 	virtual ~CalenThickLinesDrawer();
-		
+
+private slots:
+	void handleThemeChange();
+	
 private:
 	void paint(QPainter* painter, const QStyleOptionGraphicsItem* option, 
 	           QWidget* widget);
--- a/calendarui/views/resources/calenresources.qrc	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/resources/calenresources.qrc	Wed Aug 25 14:02:13 2010 +0530
@@ -5,8 +5,7 @@
         	<file>caleneventlistviewitem.widgetml</file>
 		<file>caleneventlistviewitem.css</file>
 		<file>caleneventlistviewitem_color.css</file>
-		<file>qgn_indi_cdr_meeting_layer0.svg</file>
-		<file>qtg_mono_exception.png</file>
+		<file>qtg_graf_cal_event_ind.svg</file>
     </qresource>
     <qresource prefix="/fxml">
     	<file alias="view_show">view_show_normal.fxml</file>
--- a/calendarui/views/resources/qgn_indi_cdr_meeting_layer0.svg	Mon Aug 09 18:30:52 2010 +0530
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1 Tiny//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11-tiny.dtd">
-<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" baseProfile="tiny" height="100%" preserveAspectRatio="xMidYMid meet" version="1.1" viewBox="8.151 6.36 13.047 13" width="100%" zoomAndPan="magnify">
-<g>
-<path d="M20.513,15.802l-1.189-1.838c-0.126-0.207-2.813-4.224-5.794-4.284c-0.721-0.014-2.656-0.291-2.677-0.295   l-0.034-0.004h-0.034L8.198,9.205l0.005,6.488h0.5c0.945,0,3.811,0.922,5.418,1.788c0.156,0.214,1.572,1.059,2.103,1.039   c0.508-0.018,0.854-0.393,1.023-0.633c0.34,0.088,0.965,0.342,1.309,0.132c0.287-0.177,0.478-0.507,0.58-0.784   c0.316,0.025,0.76,0.023,1.063-0.208C20.636,16.693,20.583,15.981,20.513,15.802z" fill="#F5F661"/>
-<path d="M20.542,16.22c-0.656,0.172-5.156,1.609-6.469-1.609c-1.688,0.344-5.87-0.904-5.87-0.904v1.987l1.307,0.136   c0.938,0.188,3.002,0.786,4.611,1.652c0.156,0.214,1.572,1.059,2.103,1.039c0.508-0.018,2.244-0.41,2.6-0.598   C19.12,17.767,20.558,17.407,20.542,16.22z" fill="#FFCC00"/>
-<g>
-<path d="M17.716,15.979" fill="#8CC2EA"/>
-</g>
-<g>
-<path d="M16.339,14.626" fill="#8CC2EA"/>
-</g>
-<g>
-<path d="M16.273,16.907" fill="#0046B7"/>
-</g>
-<g>
-<path d="M15.166,16.005" fill="#0046B7"/>
-</g>
-<rect fill="none" height="13" width="13" x="8.151" y="6.36"/>
-<path d="M20.488,9.385l-1.942-0.344c-0.022-0.004-3.827-0.494-3.827-0.494l-0.15-0.021l-0.137,0.069l-2.872,1.445   l-0.378,0.188l0.123,0.403c0.021,0.072,0.136,0.799,1.469,1.058c1.008,0.194,2.261-0.293,2.751-0.688l1.99,1.082   c0,0,1.617,1.816,2.374,2.803l0.92,0.817l0.39-0.088V9.385H20.488z" fill="#D98204"/>
-<path d="M16.279,15.708c-0.202-0.607-1.395-1.639-1.713-1.957c-0.398-0.401-1.723-0.857-2.01-1.095   c-0.635-0.525-1.569-0.456-1.659-0.268c-0.091,0.189-0.658,2.239-0.554,3.176c0.104,0.937,0.512,1.171,0.625,1.224   c0.188,0.084,0.463,0.096,0.731,0.08c0.114,0.288,0.28,0.592,0.528,0.729c0.264,0.146,0.748,0.16,1.176,0.139   c0.225,0.203,0.596,0.482,0.975,0.518c0.549,0.049,1.05-0.486,1.263-0.752C15.811,17.339,16.563,16.561,16.279,15.708z" fill="#D98204"/>
-<g>
-<g>
-<path d="M10.448,16.032c0.25,1.063,1.533,1.428,1.781,1.564c0.264,0.146,1.771,0.621,2.151,0.656     c0.547,0.049,1.048-0.488,1.262-0.754c0.168-0.16,0.921-0.938,0.637-1.791C14.401,18.392,10.979,16.642,10.448,16.032z      M20.345,13.552l-0.85,0.851l1.04,1.38l0.663-0.166v-2.24L20.345,13.552z" fill="#4C2B0D"/>
-</g>
-</g>
-</g>
-</svg>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/calendarui/views/resources/qtg_graf_cal_event_ind.svg	Wed Aug 25 14:02:13 2010 +0530
@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1 Tiny//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11-tiny.dtd">
+<svg baseProfile="tiny" height="10px" version="1.1" viewBox="0 0 10 10" width="10px" x="0px" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" y="0px">
+<polygon fill="#66CCAD" points="10,0 0,10 10,10 "/>
+<rect fill="none" height="10" width="10"/>
+</svg>
Binary file calendarui/views/resources/qtg_mono_exception.png has changed
--- a/calendarui/views/src/calengriditemprototype.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/src/calengriditemprototype.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -27,6 +27,7 @@
 #include <hbiconitem.h>
 #include <hbframebackground.h>
 #include <hbcolorscheme.h>
+#include <hbtheme.h>
 
 // User includes
 #include "calengriditemprototype.h"
@@ -47,19 +48,16 @@
 /*!
  Constructor.
  */
-CalenGridItemPrototype::CalenGridItemPrototype(QColor todayIndColor, QColor activeColor, QColor inActiveColor,
-                                               QGraphicsWidget *parent) :
-	HbGridViewItem(parent),
-	mTodayUnderLineColor(todayIndColor),
-	mActiveTextColor(activeColor),
-	mInActiveTextColor(inActiveColor),
-	mCurrentDateColor(Qt::black),
-	mGridBorderColor(Qt::gray),
-	mEventIndicatorItem(0),
-	mMonthDayInfoItem(0),
-	mFocusIndicatorItem(0),
-	mTodayIndicatorItem(0)
-	{
+CalenGridItemPrototype::CalenGridItemPrototype(QGraphicsWidget *parent) :
+    HbGridViewItem(parent),
+    mActiveTextColor(HbColorScheme::color("qtc_cal_month_active_dates")),
+    mInActiveTextColor(HbColorScheme::color("qtc_cal_month_notactive_dates")),
+    mCurrentDateColor(HbColorScheme::color("qtc_cal_month_highlighted_text")),
+    mEventIndicatorItem(0),
+    mMonthDayInfoItem(0),
+    mFocusIndicatorItem(0),
+    mTodayIndicatorItem(0)
+    {
     OstTraceFunctionEntry0( CALENGRIDITEMPROTOTYPE_CALENGRIDITEMPROTOTYPE_ENTRY );
     
 	OstTraceFunctionExit0( CALENGRIDITEMPROTOTYPE_CALENGRIDITEMPROTOTYPE_EXIT );
@@ -116,6 +114,9 @@
 	CalenGridItemPrototype* item = new CalenGridItemPrototype(*this);
 	item->createPrimitives();
 	
+    connect(
+            HbTheme::instance(), SIGNAL(changed()),
+            item, SLOT(handleThemeChange()));
 	// Set the default frame to NULL so that HbGridView does not add its 
 	// default frame for items
 	HbFrameBackground frame;
@@ -184,8 +185,13 @@
 			// Get the text color
 			monthTextColorRole = itemList.at(CalendarNamespace::CalendarMonthTextColorRole).value<bool>();
 			if (monthTextColorRole) {
-				// Set the active text color
-				mMonthDayInfoItem->setTextColor(mActiveTextColor);
+                if (monthFocusRole) {
+                    // Set the Highlighted text color
+                    mMonthDayInfoItem->setTextColor(mCurrentDateColor);
+                } else {
+                    // Set the active text color
+                    mMonthDayInfoItem->setTextColor(mActiveTextColor);
+                }
 			} else {
 				// Set the inactive text color
 				mMonthDayInfoItem->setTextColor(mInActiveTextColor);
@@ -233,4 +239,18 @@
 	return true;
 }
 
+/*!
+ Slot to handle the change in theme
+ */
+void CalenGridItemPrototype::handleThemeChange()
+{
+    OstTraceFunctionEntry0( CALENGRIDITEMPROTOTYPE_HANDLETHEMECHANGE_ENTRY );
+    
+    mActiveTextColor = HbColorScheme::color("qtc_cal_month_active_dates");
+    mInActiveTextColor = HbColorScheme::color("qtc_cal_month_notactive_dates");
+    mCurrentDateColor = HbColorScheme::color("qtc_cal_month_highlighted_text");
+    
+    OstTraceFunctionExit0( CALENGRIDITEMPROTOTYPE_HANDLETHEMECHANGE_EXIT );
+    
+}
 // End of file  --Don't remove this.
--- a/calendarui/views/src/calenmonthgrid.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/src/calenmonthgrid.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -65,7 +65,8 @@
 	mCurrentRow(-100),
 	mIsNonActiveDayFocused(false),
 	mIgnoreItemActivated(false),
-	mGridBorderColor(Qt::gray)
+	mGridLineColor(HbColorScheme::color("qtc_cal_grid_line")),
+    mActiveDatesSet(false)
 {
     OstTraceFunctionEntry0( CALENMONTHGRID_CALENMONTHGRID_ENTRY );
     
@@ -81,15 +82,15 @@
 	setEnabledAnimations(HbAbstractItemView::None);
 	setFrictionEnabled(false);
 	setFlag(QGraphicsItem::ItemHasNoContents, false);
+	
+	// Disable the rows and columns swapping on orientation change
+	setSwapDimensionsOnOrientationChange(false);
+	
 	resetTransform();
 	
 	// Get the content widget of the scroll area to draw the grid lines
 	mContentWidget = contentWidget();
-	
-	// Get the all required colors 
-	// Color of the grid lines
-	mGridLineColor = HbColorScheme::color("qtc_cal_grid_line");
-	
+
 	// Get the localised dates well before
 	// TODO: Need to update the mLocalisedDates when user changes the
 	// phone language keeping calendar application in background
@@ -101,6 +102,13 @@
 	// Connect to scrolling finished signal
 	connect(this, SIGNAL(scrollingEnded()), this,
 			SLOT(scrollingFinished()));
+
+    connect(
+                HbTheme::instance(), SIGNAL(changed()),
+                this, SLOT(handleThemeChange()));
+				
+	// Disable the haptic feedback for the month grid during scrolling
+    setAttribute(Hb::InteractionDisabled);
 	
 	OstTraceFunctionExit0( CALENMONTHGRID_CALENMONTHGRID_EXIT );
 }
@@ -218,19 +226,14 @@
 	}
 	
 	if (isFirstTime) {
-		// Color of the today indicator
-		QColor todayIndColor = HbColorScheme::color("qtc_cal_month_current_day");
-		// Color of the active dates
-		QColor mActiveTextColor = 
-								HbColorScheme::color("qtc_cal_month_active_dates");
-		// Color of the inactive dates
-		QColor mInActiveTextColor = 
-							HbColorScheme::color("qtc_cal_month_notactive_dates");
 		
 		// Create the prototype
-		CalenGridItemPrototype* gridItemPrototype = new CalenGridItemPrototype(
-						todayIndColor, mActiveTextColor, mInActiveTextColor, this);
+		CalenGridItemPrototype* gridItemPrototype = new CalenGridItemPrototype(this);
 		
+	    connect(
+	            HbTheme::instance(), SIGNAL(changed()),
+	            gridItemPrototype, SLOT(handleThemeChange()));
+	    
 		// Set the mode and the prototype
 		setModel(mModel,gridItemPrototype);
 		
@@ -339,15 +342,32 @@
     OstTraceFunctionEntry0( CALENMONTHGRID_DOWNGESTURE_ENTRY );
     
     // Make sure that content widget is properly placed
+    // We are doing this as tapping on inactive date of previous month is leading to
+    // position the grid at wrong place after scrolling down. Hence, set the grid
+    // at proper position before we start actual scrolling
     if (mIsNonActiveDayFocused) {
         mIsAtomicScroll = true;
         int itemToBeScrolled = mView->rowsInPrevMonth() * KCalenDaysInWeek;
         QModelIndex indexToBeScrolled  = mModel->index(itemToBeScrolled, 0);
         scrollTo(indexToBeScrolled);
     }
+   
+    // Set the required flags
     mDirection = down;
     mIsAtomicScroll = false;
-    setAttribute(Hb::InteractionDisabled);
+    
+    // Set the active and inactive dates
+    QDateTime activeMonth = mView->getActiveDay();
+    // For previous month, substract one month to the current month
+    setActiveDates(activeMonth.addMonths(-1).date());
+    mActiveDatesSet = true;
+    // Set the focus to proper date before scrolling to avoid somekind of
+    // jerkiness
+    if (!mIsNonActiveDayFocused) {
+        setFocusToProperDay();
+    }
+    
+    // Start the scrolling
     QPointF targetPos(0.0, 0.0);
     scrollContentsTo(targetPos,500);
     
@@ -361,17 +381,23 @@
 {
     OstTraceFunctionEntry0( CALENMONTHGRID_UPGESTURE_ENTRY );
     
-    // Make sure that content widget is properly placed
-    if (mIsNonActiveDayFocused) {
-        mIsAtomicScroll = true;
-        int itemToBeScrolled = mView->rowsInPrevMonth() * KCalenDaysInWeek;
-        itemToBeScrolled += KNumOfVisibleRows * KCalenDaysInWeek;
-        QModelIndex indexToBeScrolled  = mModel->index(itemToBeScrolled, 0);
-        scrollTo(indexToBeScrolled);
-    }
+   
+    // Set the required flags
     mDirection = up;
     mIsAtomicScroll = false;
-    setAttribute(Hb::InteractionDisabled);
+    
+    // Set the active and inactive dates
+    QDateTime activeMonth = mView->getActiveDay();
+    // For next month, add one month to the current month
+    setActiveDates(activeMonth.addMonths(1).date());
+    mActiveDatesSet = true;
+    // Set the focus to proper date before scrolling to avoid somekind of
+    // jerkiness
+    if (!mIsNonActiveDayFocused) {
+        setFocusToProperDay();
+    }
+    
+    // Start the scrolling
     QPointF targetPos(0.0, mStartPos.y() - size().height());
     scrollContentsTo(-targetPos,500);
 	
@@ -420,12 +446,11 @@
     
    if(HbPanGesture *gesture = qobject_cast<HbPanGesture *>(event->gesture(Qt::PanGesture))) {
         if (gesture->state() == Qt::GestureStarted) {
-            setAttribute(Hb::InteractionDisabled);
             mIsAtomicScroll = false;
             if (!mIsPanGesture) {
                 mDirection = invalid;
                 mStartPos = mContentWidget->pos();
-                // TODO: This work aroung till framework provides an api
+                // TODO: This work around till framework provides an api
                 // to know the direciton of the pan, until then we need
                 // calculate the direction explicitly
                 // Get to know the direction of the gesture
@@ -478,7 +503,6 @@
         }
     } else if(HbSwipeGesture *gesture = qobject_cast<HbSwipeGesture *>(event->gesture(Qt::SwipeGesture))) {
         if (gesture->state() == Qt::GestureStarted) {
-            setAttribute(Hb::InteractionDisabled);
             mIsAtomicScroll = false;
             mDirection = invalid;
             if (gesture->sceneVerticalDirection() == QSwipeGesture::Down) {
@@ -524,23 +548,25 @@
 	} else if(!mIsAtomicScroll) {
 		QDateTime activeDate = mView->getActiveDay();
 		if(mDirection == down) { // down gesture
-			if (!mIsNonActiveDayFocused) {
+			if (!mActiveDatesSet) {
 				setActiveDates(activeDate.addMonths(-1).date());
+				setFocusToProperDay();
 			}
 			prependRows();
 		} else if (mDirection == up) { //up gesture
-			if (!mIsNonActiveDayFocused) {
+			if (!mActiveDatesSet) {
 				setActiveDates(activeDate.addMonths(1).date());
+				setFocusToProperDay();
 			}
 			appendRows();
 		}
 		mDirection = invalid;
+		mActiveDatesSet = false;
 	} else {
         mIsAtomicScroll = false;
         mDirection = invalid;
 	}
 	mIgnoreItemActivated = false;
-	setAttribute(Hb::InteractionDisabled, false);
 	
 	OstTraceFunctionExit0( CALENMONTHGRID_SCROLLINGFINISHED_EXIT );
 }
@@ -581,7 +607,6 @@
 			// we should again show the current month by scrolling downwards
 			mDirection = down;
 			mIsAtomicScroll = true;
-			setAttribute(Hb::InteractionDisabled);
 			scrollContentsTo(-mStartPos,500);
 		}
 	} else if (month == prevMonth.date().month()) {
@@ -591,7 +616,6 @@
 			// we should again show the current month by scrolling upwards
 			mDirection = up;
 			mIsAtomicScroll = true;
-			setAttribute(Hb::InteractionDisabled);
 			scrollContentsTo(-mStartPos,500);
 		} else {
 			// down gesture to show the previous month
@@ -609,8 +633,7 @@
 			upGesture();
 		} else {
 			// we should again show the current month by scrolling upwards
-			mDirection = invalid;
-			setAttribute(Hb::InteractionDisabled);
+			mDirection = up;
 			scrollContentsTo(-mStartPos,500);
 		}
 	} else if (month == nextMonth.addMonths(1).date().month()) {
@@ -629,13 +652,6 @@
 void CalenMonthGrid::prependRows()
 {
     OstTraceFunctionEntry0( CALENMONTHGRID_PREPENDROWS_ENTRY );
-    
-	// Before we do anything, set the focus to proper date
-	// Set it only when non active day was focussed. When inactive day
-	// was focussed, we need to focus the same day
-	if (!mIsNonActiveDayFocused) {
-		setFocusToProperDay();
-	}
 	
 	// Block the signals generated by model, this is being done as
 	// we want to avoid the overload of view listening to signals
@@ -756,13 +772,6 @@
 void CalenMonthGrid::appendRows()
 {
     OstTraceFunctionEntry0( CALENMONTHGRID_APPENDROWS_ENTRY );
-    
-	// Before we do anything, set the focus to proper date
-	// Set it only when non active day was focussed. When inactive day
-	// was focussed, we need to focus the same day
-	if (!mIsNonActiveDayFocused) {
-		setFocusToProperDay();
-	}
 	
 	// Block the signals generated by model, this is being done as
 	// we want to avoid the overload of view listening to signals
@@ -924,21 +933,19 @@
 		if(month != monthDataList[mCurrentRow].Day().date().month()){
 			// Set the flag
 			mIsNonActiveDayFocused = true;
-			mNonActiveFocusedDay = monthDataList[mCurrentRow].Day();
+			QDateTime nonActiveFocusedDay = monthDataList[mCurrentRow].Day();
 			
 			// Add one month to active month
 			activeMonth = activeMonth.addMonths(1);
 			if (activeMonth.date().month() == 
-				mNonActiveFocusedDay.date().month()) {
+			        nonActiveFocusedDay.date().month()) {
 				mDirection = up;
 				// up gesture
 				upGesture();
-				setActiveDates(activeMonth.date());
 			} else {
 				mDirection = down;
 				// down gesture
 				downGesture();
-				setActiveDates(activeMonth.addMonths(-2).date());
 			}
 		} 
 		mView->setContextForActiveDay(index.row());
@@ -1025,12 +1032,14 @@
 	end = firstDateInGrid.daysTo(endOfActiveMonth);
 	
 	// Set the active text color
-	for (int i = start; i < end; i++) {	
-		QModelIndex index = mModel->index(i,0);
-		QVariant itemData = index.data(Qt::UserRole + 1);
-		QVariantList list = itemData.toList();
-		list.replace(CalendarNamespace::CalendarMonthTextColorRole, true);
-		mModel->itemFromIndex(index)->setData(list);
+	if (start >= 0 && end < monthDataList.count()) {
+        for (int i = start; i < end; i++) {	
+            QModelIndex index = mModel->index(i,0);
+            QVariant itemData = index.data(Qt::UserRole + 1);
+            QVariantList list = itemData.toList();
+            list.replace(CalendarNamespace::CalendarMonthTextColorRole, true);
+            mModel->itemFromIndex(index)->setData(list);
+        }
 	}
 	
 	// Now set the inactive text color to those which were active before the swipe
@@ -1071,12 +1080,14 @@
 	}
 	
 	// Set the inactive text color
-	for (int i = start; i < end; i++) {		
-		QModelIndex index = mModel->index(i,0);
-		QVariant itemData = index.data(Qt::UserRole + 1);
-		QVariantList list = itemData.toList();
-		list.replace(CalendarNamespace::CalendarMonthTextColorRole, false);
-		mModel->itemFromIndex(index)->setData(list);
+	if (start >= 0 && end < monthDataList.count()) {
+        for (int i = start; i < end; i++) {		
+            QModelIndex index = mModel->index(i,0);
+            QVariant itemData = index.data(Qt::UserRole + 1);
+            QVariantList list = itemData.toList();
+            list.replace(CalendarNamespace::CalendarMonthTextColorRole, false);
+            mModel->itemFromIndex(index)->setData(list);
+        }
 	}
 	
 	OstTraceFunctionExit0( DUP1_CALENMONTHGRID_SETACTIVEDATES_EXIT );
@@ -1162,11 +1173,8 @@
 	qreal widthInPixels = GRIDLINE_WIDTH * unitValue;
 	pen.setStyle(Qt::SolidLine);
 	pen.setWidth(widthInPixels);
-	if (mGridLineColor.isValid()) {
-		pen.setBrush(mGridLineColor);
-	} else {
-		pen.setBrush(mGridBorderColor);
-	}
+	pen.setBrush(mGridLineColor);
+	
 	// Store the old pen
 	QPen oldPen = painter->pen();
 	
@@ -1235,4 +1243,16 @@
 	OstTraceFunctionExit0( CALENMONTHGRID_PAINT_EXIT );
 }
 
+/*!
+ Slot to handle the change in theme
+ */
+void CalenMonthGrid::handleThemeChange()
+{
+    OstTraceFunctionEntry0(CALENMONTHGRID_HANDLETHEMECHANGE_ENTRY);
+    
+    mGridLineColor = HbColorScheme::color("qtc_cal_grid_line");
+    
+    OstTraceFunctionExit0(CALENMONTHGRID_HANDLETHEMECHANGE_EXIT);
+}
+
 // End of File
--- a/calendarui/views/src/calenmonthview.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/src/calenmonthview.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -27,6 +27,7 @@
 #include <hblabel.h>
 #include <hbframeitem.h>
 #include <hbcolorscheme.h>
+#include <hbtheme.h>
 #include <agendautil.h>
 #include <agendaentry.h>
 #include <hbapplication.h> // hbapplication
@@ -93,9 +94,14 @@
 	mLocale = HbExtendedLocale::system();
 	mFirstWeekLabel = NULL;
 	mIsPrevPaneGesture = false;
-	// Get the week day color from the theme
+	// Get the week day and preview heading color from the theme
 	mWeekDaysColor = HbColorScheme::color("qtc_cal_week_day");
 	
+	mPreviewHeadingColor = HbColorScheme::color("qtc_cal_day_preview_heading");
+	
+    connect(HbTheme::instance(), SIGNAL(changed()),
+                this, SLOT(handleThemeChange()));
+    
 	OstTraceFunctionExit0( CALENMONTHVIEW_CALENMONTHVIEW_EXIT );
 }
 
@@ -179,6 +185,10 @@
 	mCurrPreviewPane->setView(this);
 	mCurrPreviewPane->setNoEntriesLabel(currPaneNoEntriesLabel);
 	
+    connect(
+            HbTheme::instance(), SIGNAL(changed()),
+            mCurrPreviewPane, SLOT(handleThemeChange()));
+	
 	mCurrPaneLayoutWidget = qobject_cast<HbWidget*>(docLoader->findWidget(CALEN_CURRPANELAYOUT));
 	mCurrPaneLayout = static_cast<QGraphicsLinearLayout*>(mCurrPaneLayoutWidget->layout());
 	
@@ -194,6 +204,9 @@
 			docLoader->findWidget(CALEN_NOENTRIES_LABEL_PREV));
 	mPrevPreviewPane->setView(this);
 	mPrevPreviewPane->setNoEntriesLabel(prevPaneNoEntriesLabel);
+    connect(
+            HbTheme::instance(), SIGNAL(changed()),
+            mPrevPreviewPane, SLOT(handleThemeChange()));
 	mPrevPaneParent->setVisible(false);
 	
 	mPrevPaneLayoutWidget = qobject_cast<HbWidget*>(docLoader->findWidget(CALEN_PREVPANELAYOUT));
@@ -210,6 +223,10 @@
 			docLoader->findWidget(CALEN_NOENTRIES_LABEL_NEXT));
 	mNextPreviewPane->setView(this);
 	mNextPreviewPane->setNoEntriesLabel(nextPaneNoEntriesLabel);
+    connect(
+            HbTheme::instance(), SIGNAL(changed()),
+            mNextPreviewPane, SLOT(handleThemeChange()));
+    
 	mNextPaneParent->setVisible(false);
 	mNextPaneLayoutWidget = qobject_cast<HbWidget*>(docLoader->findWidget(CALEN_NEXTPANELAYOUT));
 	mNextPaneLayout = static_cast<QGraphicsLinearLayout*>(mNextPaneLayoutWidget->layout());
@@ -560,8 +577,11 @@
 			}
 			QString *pluginString = pluginText();
 			mPrevRegionalInfo->setPlainText(*pluginString);
+			mPrevRegionalInfo->setTextColor(mPreviewHeadingColor);
 			mCurrRegionalInfo->setPlainText(*pluginString);
+			mCurrRegionalInfo->setTextColor(mPreviewHeadingColor);
 			mNextRegionalInfo->setPlainText(*pluginString);
+			mNextRegionalInfo->setTextColor(mPreviewHeadingColor);
 		} else {
 			if (mPrevRegionalInfo) {
 				mPrevPaneLayout->removeItem(mPrevRegionalInfo);
@@ -1427,16 +1447,27 @@
 	mServices.IssueCommandL(ECalenDayView);
 	// day view launched now, disconnect to get the call backs for saveActivity 
 	// on aboutToQuit signal
-	if (mIsAboutToQuitEventConnected)
-	    {
-        disconnect(qobject_cast<HbApplication*>(qApp), SIGNAL(aboutToQuit()), this, SLOT(saveActivity()));
-        mIsAboutToQuitEventConnected = false;
-	    }
+	disconnectAboutToQuitEvent();
 	
 	OstTraceFunctionExit0( CALENMONTHVIEW_LAUNCHDAYVIEW_EXIT );
 }
 
 /*!
+disconnects for the aboutToQuit events
+ */
+void CalenMonthView::disconnectAboutToQuitEvent()
+{
+	OstTraceFunctionEntry0( CALENMONTHVIEW_DISCONNECTABOUTTOQUITEVENT_ENTRY );
+	
+	if (mIsAboutToQuitEventConnected) {
+		disconnect(qobject_cast<HbApplication*>(qApp), SIGNAL(aboutToQuit()), this, SLOT(saveActivity()));
+		mIsAboutToQuitEventConnected = false;
+	}
+	
+	OstTraceFunctionExit0( CALENMONTHVIEW_DISCONNECTABOUTTOQUITEVENT_EXIT );
+}
+
+/*!
  Slot to handle the change in orientation
  */
 void CalenMonthView::changeOrientation(Qt::Orientation orientation)
@@ -1453,6 +1484,28 @@
 }
 
 /*!
+ Slot to handle the change in theme
+ */
+void CalenMonthView::handleThemeChange()
+{
+    OstTraceFunctionEntry0( CALENMONTHVIEW_HANDLETHEMECHANGE_ENTRY );
+    
+    // Refresh the month view when the theme change happens
+    mWeekDaysColor = HbColorScheme::color("qtc_cal_week_day");
+    QColor monthTitleColor = HbColorScheme::color("qtc_cal_monthgrid_title");
+    
+    if (mTitleLabel && monthTitleColor.isValid()) {
+		mTitleLabel->setTextColor(monthTitleColor);
+	}
+    
+    mPreviewHeadingColor = HbColorScheme::color("qtc_cal_day_preview_heading");
+    
+    mServices.IssueCommandL(ECalenStartActiveStep);
+    
+    OstTraceFunctionExit0( CALENMONTHVIEW_HANDLETHEMECHANGE_EXIT );
+}
+
+/*!
  Loads appropriate section from the docml dsepending on the current orientation
  of the device
  */
@@ -1721,9 +1774,12 @@
     labels.append(mFifthDayLabel);
     labels.append(mSixthDayLabel);
     labels.append(mSeventhDayLabel);
+    QGraphicsLinearLayout* layout = static_cast<QGraphicsLinearLayout*> (mDayNameWidget->layout());
     for(int i=0;i < KCalenDaysInWeek; i++ )
         {
         labels.at(i)->setPlainText(weekDayArray[weekDayIndex]);
+        // Set the stretch factor as 1 so that each label occupies equal space
+        layout->setStretchFactor(labels.at(i), 1);
         if(weekDayIndex == KCalenDaysInWeek - 1 )//Sunday
             {
             weekDayIndex = 0;//reset to monday
--- a/calendarui/views/src/calenpreviewpane.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/src/calenpreviewpane.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -74,6 +74,8 @@
 	mNoEntriesLabel = 0;
 	mHtDiff = 0.0;
 	mScrollDuration = 0;
+	mPreviewTextColor = HbColorScheme::color("qtc_cal_day_preview_text");
+	
 	setAcceptDrops(true);
 	setScrollDirections(Qt::Vertical);
 	setVerticalScrollBarPolicy(HbScrollArea::ScrollBarAlwaysOff);
@@ -107,6 +109,9 @@
     
 	mNoEntriesLabel = label;
 	
+	if (mPreviewTextColor.isValid()) {
+		mNoEntriesLabel->setTextColor(mPreviewTextColor);
+	}
 	OstTraceFunctionExit0( CALENPREVIEWPANE_SETNOENTRIESLABEL_EXIT );
 }
 
@@ -138,6 +143,9 @@
 	HbFontSpec font(HbFontSpec::Secondary);
 	if (mIsNoEntriesAdded) {
 		if (!instanceCount) {
+			if (mPreviewTextColor.isValid()) {
+				mNoEntriesLabel->setTextColor(mPreviewTextColor);
+			}
 		    mNoEntriesLabel->setVisible(true);
 		    OstTraceFunctionExit0( CALENPREVIEWPANE_POPULATELABEL_EXIT );
 		    return;
@@ -162,13 +170,6 @@
 				// Set the required font
 				label->setFontSpec(font);
 				
-				// Set the text color from the theme
-				QColor previewPaneColor = HbColorScheme::color(
-												"qtc_cal_day_preview_text");
-				if (previewPaneColor.isValid()) {
-				    label->setTextColor(previewPaneColor);
-				}
-				
 				// Set the elide mode to right
 				label->setElideMode(Qt::ElideRight);
 				// Add the label to the list
@@ -179,6 +180,10 @@
 				label = mLabelList.at(i);
 				count--;
 			}
+			
+			if (mPreviewTextColor.isValid()) {
+				label->setTextColor(mPreviewTextColor);
+			}
 			QString summary = mInstanceArray[i].summary();
 			if(!summary.length()) {
 				// No summary display "Unnamed"
@@ -234,6 +239,9 @@
 		// Clear the list
 		mLabelList.clear();
 		
+		if (mPreviewTextColor.isValid()) {
+			mNoEntriesLabel->setTextColor(mPreviewTextColor);
+		}
 		// Add the no entries text to the preview pane
 		mNoEntriesLabel->setVisible(true);
 		mIsNoEntriesAdded = true;
@@ -431,11 +439,12 @@
             	HbInstantFeedback::play(HbFeedback::Basic);
                 // Preview pane tapped
                 mServices.IssueCommandL(ECalenAgendaView);
+                mView->disconnectAboutToQuitEvent();
                 event->accept(Qt::TapGesture);
         }
     }
     
-    OstTraceFunctionExit0( DUP2_CALENPREVIEWPANE_GESTUREEVENT_EXIT );
+    OstTraceFunctionExit0( DUP3_CALENPREVIEWPANE_GESTUREEVENT_EXIT );
 }
 
 /*!
@@ -499,4 +508,16 @@
     mIsGestureHandled = false;
 }
 
+/*!
+ Slot to handle the change in theme
+ */
+void CalenPreviewPane::handleThemeChange()
+{
+    OstTraceFunctionEntry0( CALENPREVIEWPANE_HANDLETHEMECHANGE_ENTRY );
+    
+    mPreviewTextColor = HbColorScheme::color("qtc_cal_day_preview_text");
+    
+    OstTraceFunctionExit0( CALENPREVIEWPANE_HANDLETHEMECHANGE_EXIT );
+}
+
 // End of file  --Don't remove this.
--- a/calendarui/views/src/calenthicklinesdrawer.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/src/calenthicklinesdrawer.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -21,6 +21,7 @@
 #include <QPen>
 #include <hbdeviceprofile.h>
 #include <hbcolorscheme.h>
+#include <hbtheme.h>
 
 // User includes
 #include "calenthicklinesdrawer.h"
@@ -53,6 +54,10 @@
 	mGridBorderColor = HbColorScheme::color("qtc_cal_grid_line");
 	setFlag(QGraphicsItem::ItemHasNoContents, false);
 	
+	connect(
+				HbTheme::instance(), SIGNAL(changed()),
+				this, SLOT(handleThemeChange()));
+	
 	OstTraceFunctionExit0( CALENTHICKLINESDRAWER_CALENTHICKLINESDRAWER_EXIT );
 }
 
@@ -121,4 +126,16 @@
     OstTraceFunctionExit0( CALENTHICKLINESDRAWER_PAINT_EXIT );
 }
 
+/*!
+ Slot to handle the change in theme
+ */
+void CalenThickLinesDrawer::handleThemeChange()
+{
+	OstTraceFunctionEntry0(CALENTHICKLINESDRAWER_HANDLETHEMECHANGE_ENTRY);
+	
+	mGridBorderColor = HbColorScheme::color("qtc_cal_grid_line");
+	
+	OstTraceFunctionExit0(CALENTHICKLINESDRAWER_HANDLETHEMECHANGE_EXIT);
+}
+
 // End of file  --Don't remove this.
--- a/calendarui/views/traces/calengriditemprototypeTraces.h	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/traces/calengriditemprototypeTraces.h	Wed Aug 25 14:02:13 2010 +0530
@@ -20,6 +20,8 @@
 #define DUP1_CALENGRIDITEMPROTOTYPE_PRESSSTATECHANGED_EXIT 0x8a0079
 #define CALENGRIDITEMPROTOTYPE_CANSETMODELINDEX_ENTRY 0x8a007a
 #define CALENGRIDITEMPROTOTYPE_CANSETMODELINDEX_EXIT 0x8a007b
+#define CALENGRIDITEMPROTOTYPE_HANDLETHEMECHANGE_ENTRY 0x8a0183
+#define CALENGRIDITEMPROTOTYPE_HANDLETHEMECHANGE_EXIT 0x8a0184
 
 
 #endif
--- a/calendarui/views/traces/calenmonthgridTraces.h	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/traces/calenmonthgridTraces.h	Wed Aug 25 14:02:13 2010 +0530
@@ -60,6 +60,8 @@
 #define CALENMONTHGRID_ORIENTATIONCHANGED_EXIT 0x8a00bf
 #define CALENMONTHGRID_PAINT_ENTRY 0x8a00c0
 #define CALENMONTHGRID_PAINT_EXIT 0x8a00c1
+#define CALENMONTHGRID_HANDLETHEMECHANGE_ENTRY 0x8a0185
+#define CALENMONTHGRID_HANDLETHEMECHANGE_EXIT 0x8a0186
 
 
 #endif
--- a/calendarui/views/traces/calenmonthviewTraces.h	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/traces/calenmonthviewTraces.h	Wed Aug 25 14:02:13 2010 +0530
@@ -105,6 +105,10 @@
 #define CALENMONTHVIEW_HANDLERIGHTEFFECTCOMPLETED_EXIT 0x8a0122
 #define CALENMONTHVIEW_UPDATEDAYLABEL_ENTRY 0x8a0123
 #define CALENMONTHVIEW_UPDATEDAYLABEL_EXIT 0x8a0124
+#define CALENMONTHVIEW_DISCONNECTABOUTTOQUITEVENT_ENTRY 0x8a017f
+#define CALENMONTHVIEW_DISCONNECTABOUTTOQUITEVENT_EXIT 0x8a0180
+#define CALENMONTHVIEW_HANDLETHEMECHANGE_ENTRY 0x8a0187
+#define CALENMONTHVIEW_HANDLETHEMECHANGE_EXIT 0x8a0188
 
 
 #endif
--- a/calendarui/views/traces/calenpreviewpaneTraces.h	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/traces/calenpreviewpaneTraces.h	Wed Aug 25 14:02:13 2010 +0530
@@ -30,11 +30,14 @@
 #define CALENPREVIEWPANE_GESTUREEVENT_ENTRY 0x8a015f
 #define CALENPREVIEWPANE_GESTUREEVENT_EXIT 0x8a0160
 #define DUP1_CALENPREVIEWPANE_GESTUREEVENT_EXIT 0x8a0161
-#define DUP2_CALENPREVIEWPANE_GESTUREEVENT_EXIT 0x8a0162
 #define CALENPREVIEWPANE_SETVIEW_ENTRY 0x8a0163
 #define CALENPREVIEWPANE_SETVIEW_EXIT 0x8a0164
 #define CALENPREVIEWPANE_STOPSCROLLING_ENTRY 0x8a0165
 #define CALENPREVIEWPANE_STOPSCROLLING_EXIT 0x8a0166
+#define DUP2_CALENPREVIEWPANE_GESTUREEVENT_EXIT 0x8a0181
+#define DUP3_CALENPREVIEWPANE_GESTUREEVENT_EXIT 0x8a0182
+#define CALENPREVIEWPANE_HANDLETHEMECHANGE_ENTRY 0x8a0189
+#define CALENPREVIEWPANE_HANDLETHEMECHANGE_EXIT 0x8a018a
 
 
 #endif
--- a/calendarui/views/traces/calenthicklinesdrawerTraces.h	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/traces/calenthicklinesdrawerTraces.h	Wed Aug 25 14:02:13 2010 +0530
@@ -12,6 +12,8 @@
 #define DUP1_CALENTHICKLINESDRAWER_CALENTHICKLINESDRAWER_EXIT 0x8a0174
 #define CALENTHICKLINESDRAWER_PAINT_ENTRY 0x8a0175
 #define CALENTHICKLINESDRAWER_PAINT_EXIT 0x8a0176
+#define CALENTHICKLINESDRAWER_HANDLETHEMECHANGE_ENTRY 0x8a018b
+#define CALENTHICKLINESDRAWER_HANDLETHEMECHANGE_EXIT 0x8a018c
 
 
 #endif
--- a/calendarui/views/traces/fixed_id.definitions	Mon Aug 09 18:30:52 2010 +0530
+++ b/calendarui/views/traces/fixed_id.definitions	Wed Aug 25 14:02:13 2010 +0530
@@ -98,6 +98,8 @@
 [TRACE]TRACE_FLOW[0x8A]_CALENGRIDITEMPROTOTYPE_CREATEITEM_EXIT=0x73
 [TRACE]TRACE_FLOW[0x8A]_CALENGRIDITEMPROTOTYPE_CREATEPRIMITIVES_ENTRY=0x70
 [TRACE]TRACE_FLOW[0x8A]_CALENGRIDITEMPROTOTYPE_CREATEPRIMITIVES_EXIT=0x71
+[TRACE]TRACE_FLOW[0x8A]_CALENGRIDITEMPROTOTYPE_HANDLETHEMECHANGE_ENTRY=0x183
+[TRACE]TRACE_FLOW[0x8A]_CALENGRIDITEMPROTOTYPE_HANDLETHEMECHANGE_EXIT=0x184
 [TRACE]TRACE_FLOW[0x8A]_CALENGRIDITEMPROTOTYPE_PRESSSTATECHANGED_ENTRY=0x76
 [TRACE]TRACE_FLOW[0x8A]_CALENGRIDITEMPROTOTYPE_PRESSSTATECHANGED_EXIT=0x77
 [TRACE]TRACE_FLOW[0x8A]_CALENGRIDITEMPROTOTYPE_UPDATECHILDITEMS_ENTRY=0x74
@@ -130,6 +132,8 @@
 [TRACE]TRACE_FLOW[0x8A]_CALENMONTHGRID_HANDLEPANGESTUREFINISHED_EXIT=0xa8
 [TRACE]TRACE_FLOW[0x8A]_CALENMONTHGRID_HANDLEPREPENDINGROWS_ENTRY=0xab
 [TRACE]TRACE_FLOW[0x8A]_CALENMONTHGRID_HANDLEPREPENDINGROWS_EXIT=0xac
+[TRACE]TRACE_FLOW[0x8A]_CALENMONTHGRID_HANDLETHEMECHANGE_ENTRY=0x185
+[TRACE]TRACE_FLOW[0x8A]_CALENMONTHGRID_HANDLETHEMECHANGE_EXIT=0x186
 [TRACE]TRACE_FLOW[0x8A]_CALENMONTHGRID_ITEMACTIVATED_ENTRY=0xb1
 [TRACE]TRACE_FLOW[0x8A]_CALENMONTHGRID_ITEMACTIVATED_EXIT=0xb2
 [TRACE]TRACE_FLOW[0x8A]_CALENMONTHGRID_MOUSEPRESSEVENT_ENTRY=0x9c
@@ -178,6 +182,8 @@
 [TRACE]TRACE_FLOW[0x8A]_CALENMONTHVIEW_CREATEGRID_EXIT=0xee
 [TRACE]TRACE_FLOW[0x8A]_CALENMONTHVIEW_DATEFROMCONTEXT_ENTRY=0xe1
 [TRACE]TRACE_FLOW[0x8A]_CALENMONTHVIEW_DATEFROMCONTEXT_EXIT=0xe2
+[TRACE]TRACE_FLOW[0x8A]_CALENMONTHVIEW_DISCONNECTABOUTTOQUITEVENT_ENTRY=0x17f
+[TRACE]TRACE_FLOW[0x8A]_CALENMONTHVIEW_DISCONNECTABOUTTOQUITEVENT_EXIT=0x180
 [TRACE]TRACE_FLOW[0x8A]_CALENMONTHVIEW_DOLAZYLOADING_ENTRY=0xc8
 [TRACE]TRACE_FLOW[0x8A]_CALENMONTHVIEW_DOLAZYLOADING_EXIT=0xc9
 [TRACE]TRACE_FLOW[0x8A]_CALENMONTHVIEW_DOPOPULATION_ENTRY=0xdb
@@ -206,6 +212,8 @@
 [TRACE]TRACE_FLOW[0x8A]_CALENMONTHVIEW_HANDLEPREVIEWPANEGESTURE_EXIT=0x11a
 [TRACE]TRACE_FLOW[0x8A]_CALENMONTHVIEW_HANDLERIGHTEFFECTCOMPLETED_ENTRY=0x121
 [TRACE]TRACE_FLOW[0x8A]_CALENMONTHVIEW_HANDLERIGHTEFFECTCOMPLETED_EXIT=0x122
+[TRACE]TRACE_FLOW[0x8A]_CALENMONTHVIEW_HANDLETHEMECHANGE_ENTRY=0x187
+[TRACE]TRACE_FLOW[0x8A]_CALENMONTHVIEW_HANDLETHEMECHANGE_EXIT=0x188
 [TRACE]TRACE_FLOW[0x8A]_CALENMONTHVIEW_LAUNCHDAYVIEW_ENTRY=0x111
 [TRACE]TRACE_FLOW[0x8A]_CALENMONTHVIEW_LAUNCHDAYVIEW_EXIT=0x112
 [TRACE]TRACE_FLOW[0x8A]_CALENMONTHVIEW_MONTHDATALIST_ENTRY=0xeb
@@ -296,6 +304,8 @@
 [TRACE]TRACE_FLOW[0x8A]_CALENPREVIEWPANE_GESTUREEVENT_EXIT=0x160
 [TRACE]TRACE_FLOW[0x8A]_CALENPREVIEWPANE_GETINSTANCELISTL_ENTRY=0x153
 [TRACE]TRACE_FLOW[0x8A]_CALENPREVIEWPANE_GETINSTANCELISTL_EXIT=0x154
+[TRACE]TRACE_FLOW[0x8A]_CALENPREVIEWPANE_HANDLETHEMECHANGE_ENTRY=0x189
+[TRACE]TRACE_FLOW[0x8A]_CALENPREVIEWPANE_HANDLETHEMECHANGE_EXIT=0x18a
 [TRACE]TRACE_FLOW[0x8A]_CALENPREVIEWPANE_ONTWOSECONDSTIMEOUT_ENTRY=0x15a
 [TRACE]TRACE_FLOW[0x8A]_CALENPREVIEWPANE_ONTWOSECONDSTIMEOUT_EXIT=0x15b
 [TRACE]TRACE_FLOW[0x8A]_CALENPREVIEWPANE_POPULATELABEL_ENTRY=0x150
@@ -320,6 +330,8 @@
 [TRACE]TRACE_FLOW[0x8A]_CALENSETTINGSVIEW_REFRESHVIEW_EXIT=0x170
 [TRACE]TRACE_FLOW[0x8A]_CALENTHICKLINESDRAWER_CALENTHICKLINESDRAWER_ENTRY=0x171
 [TRACE]TRACE_FLOW[0x8A]_CALENTHICKLINESDRAWER_CALENTHICKLINESDRAWER_EXIT=0x172
+[TRACE]TRACE_FLOW[0x8A]_CALENTHICKLINESDRAWER_HANDLETHEMECHANGE_ENTRY=0x18b
+[TRACE]TRACE_FLOW[0x8A]_CALENTHICKLINESDRAWER_HANDLETHEMECHANGE_EXIT=0x18c
 [TRACE]TRACE_FLOW[0x8A]_CALENTHICKLINESDRAWER_PAINT_ENTRY=0x175
 [TRACE]TRACE_FLOW[0x8A]_CALENTHICKLINESDRAWER_PAINT_EXIT=0x176
 [TRACE]TRACE_FLOW[0x8A]_CALENTODAYINDICATORLINEDRAWER_CALENTODAYINDICATORLINEDRAWER_ENTRY=0x177
@@ -380,5 +392,7 @@
 [TRACE]TRACE_FLOW[0x8A]_DUP2_CALENMONTHDATA_CALENMONTHDATA_EXIT=0x81
 [TRACE]TRACE_FLOW[0x8A]_DUP2_CALENMONTHGRID_GESTUREEVENT_EXIT=0xa3
 [TRACE]TRACE_FLOW[0x8A]_DUP2_CALENMONTHGRID_ITEMACTIVATED_EXIT=0xb4
-[TRACE]TRACE_FLOW[0x8A]_DUP2_CALENPREVIEWPANE_GESTUREEVENT_EXIT=0x162
+[TRACE]TRACE_FLOW[0x8A]_DUP2_CALENPREVIEWPANE_GESTUREEVENT_EXIT=0x181
 [TRACE]TRACE_FLOW[0x8A]_DUP3_CALENMONTHGRID_GESTUREEVENT_EXIT=0xa4
+[TRACE]TRACE_FLOW[0x8A]_DUP3_CALENPREVIEWPANE_GESTUREEVENT_EXIT=0x182
+[[OBSOLETE]][TRACE]TRACE_FLOW[0x8A]_DUP2_CALENPREVIEWPANE_GESTUREEVENT_EXIT=0x162
--- a/clock/clock.pro	Mon Aug 09 18:30:52 2010 +0530
+++ b/clock/clock.pro	Wed Aug 25 14:02:13 2010 +0530
@@ -29,8 +29,7 @@
     "./rom/clockengines.iby             CORE_APP_LAYER_IBY_EXPORT_PATH(clockengines.iby)" \
 	"./rom/clockresources.iby           LANGUAGE_APP_LAYER_IBY_EXPORT_PATH(clockresources.iby)" \
 	\
-    "./conf/clockapp.confml             APP_LAYER_CONFML(clockapp.confml)" \
-	"./conf/CI_clockapp.confml			APP_LAYER_CONFML(CI_clockapp.confml)" \
+    "./conf/clockapp.confml             APP_LAYER_CONFML(clockapp.confml)" \	
     "./conf/clockapp_101F874D.crml      APP_LAYER_CRML(clockapp_101F874D.crml)" \
     "./conf/clockapp_101F8876.crml      APP_LAYER_CRML(clockapp_101F8876.crml)" \
 	# stubsis is added to provide IAD
--- a/clock/clockui/clockalarmeditor/src/clockalarmeditor.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/clock/clockui/clockalarmeditor/src/clockalarmeditor.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -362,6 +362,9 @@
 		// Check if the Alarm days item is added.
 		// Remove if already added.
 		if (mAlarmDayItemInserted) {
+			mAlarmEditorForm->removeConnection(
+								mAlarmDayItem, SIGNAL(currentIndexChanged(int)),
+								this, SLOT(handleDayChanged(int)));
 			mAlarmEditorModel->removeItem(mAlarmDayItem);
 			mAlarmDayItemInserted = false;
 		}
@@ -524,7 +527,8 @@
 		
 		editor->setSelection(0, 0);
 		if (editor->text().isEmpty()) {
-	        editor->setText(hbTrId("txt_clk_formlabel_val_alarm"));
+	    	mAlarmDescription->setContentWidgetData(
+	    			"text", hbTrId("txt_clk_formlabel_val_alarm"));
         }
 
 	}
--- a/clock/clockui/clockplugins/datetimesettingsplugin/inc/datetimesettingsplugin.h	Mon Aug 09 18:30:52 2010 +0530
+++ b/clock/clockui/clockplugins/datetimesettingsplugin/inc/datetimesettingsplugin.h	Wed Aug 25 14:02:13 2010 +0530
@@ -23,9 +23,11 @@
 // System includes
 #include <QObject>
 
-// User includes
+// User includes.
 #include <cpplugininterface.h>
 
+// Forward class declartion.
+class HbTranslator;
 class DateTimeSettingsPlugin : public QObject, public CpPluginInterface
 {
 	Q_OBJECT
@@ -37,6 +39,9 @@
 
 	virtual int uid() const;
 	QList<CpSettingFormItemData*> createSettingFormItemData(CpItemDataHelper &itemDataHelper) const;
+	
+private:
+	HbTranslator *mTranslator;
 };
 
 #endif /* DATETIMESETTINGSPLUGIN_H_ */
--- a/clock/clockui/clockplugins/datetimesettingsplugin/inc/datetimesettingsview.h	Mon Aug 09 18:30:52 2010 +0530
+++ b/clock/clockui/clockplugins/datetimesettingsplugin/inc/datetimesettingsview.h	Wed Aug 25 14:02:13 2010 +0530
@@ -25,6 +25,7 @@
 // Forward declarations
 class QTimer;
 class TimezoneClient;
+class HbTranslator;
 
 class DateTimeSettingsView : public CpSettingFormEntryItemData
 {
@@ -34,7 +35,8 @@
 			CpItemDataHelper &itemDataHelper, const QString &text = QString(),
 			const QString &description = QString(),
 			const HbIcon &icon = HbIcon(),
-			const HbDataFormModelItem *parent = 0);
+			const HbDataFormModelItem *parent = 0,
+			HbTranslator *translator = 0);
 	virtual ~DateTimeSettingsView();
 
 private slots:
@@ -47,6 +49,7 @@
 private:
 	QTimer *mTickTimer;
 	TimezoneClient *mTimezoneClient;
+	HbTranslator *mTranslator;
 
 };
 
--- a/clock/clockui/clockplugins/datetimesettingsplugin/src/datetimesettingsplugin.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/clock/clockui/clockplugins/datetimesettingsplugin/src/datetimesettingsplugin.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -19,6 +19,7 @@
 #include <QDateTime>
 #include <cpsettingformentryitemdataimpl.h>
 #include <HbExtendedLocale>
+#include <HbTranslator>
 
 // User includes
 #include "datetimesettingsplugin.h"
@@ -35,6 +36,8 @@
 DateTimeSettingsPlugin::DateTimeSettingsPlugin()
 {
 	OstTraceFunctionEntry0( DATETIMESETTINGSPLUGIN_DATETIMESETTINGSPLUGIN_ENTRY );
+	mTranslator = new HbTranslator("clocksettingsview");
+	mTranslator->loadCommon();
 	OstTraceFunctionExit0( DATETIMESETTINGSPLUGIN_DATETIMESETTINGSPLUGIN_EXIT );
 }
 
@@ -44,6 +47,10 @@
 DateTimeSettingsPlugin::~DateTimeSettingsPlugin()
 {
 	OstTraceFunctionEntry0( DUP1_DATETIMESETTINGSPLUGIN_DATETIMESETTINGSPLUGIN_ENTRY );
+	if(mTranslator) {
+	    delete mTranslator;
+	    mTranslator = 0;
+	}
 	OstTraceFunctionExit0( DUP1_DATETIMESETTINGSPLUGIN_DATETIMESETTINGSPLUGIN_EXIT );
 }
 
@@ -66,7 +73,8 @@
 							  CpItemDataHelper &itemDataHelper) const
 {
 	OstTraceFunctionEntry0( DATETIMESETTINGSPLUGIN_CREATESETTINGFORMITEMDATA_ENTRY );
-	HbIcon icon ;
+	HbIcon icon ;	
+	
 	HbExtendedLocale locale = HbExtendedLocale::system();
 	QString timeInfo = locale.format(
 			QTime::currentTime(), r_qtn_time_usual_with_zero);
@@ -79,8 +87,8 @@
 	
 	QList<CpSettingFormItemData*> entryItemList;
 	CpSettingFormItemData *entryItem = new DateTimeSettingsView(
-			itemDataHelper,hbTrId("txt_cp_main_view_list_time_date"),
-			displayString,icon);
+			itemDataHelper, hbTrId("txt_cp_main_view_list_time_date"),
+			displayString,icon, 0, mTranslator);
 	entryItemList.append(entryItem);
 	OstTraceFunctionExit0( DATETIMESETTINGSPLUGIN_CREATESETTINGFORMITEMDATA_EXIT );
 	return entryItemList;
--- a/clock/clockui/clockplugins/datetimesettingsplugin/src/datetimesettingsview.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/clock/clockui/clockplugins/datetimesettingsplugin/src/datetimesettingsview.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -50,12 +50,13 @@
 DateTimeSettingsView::DateTimeSettingsView(
 		CpItemDataHelper &itemDataHelper, const QString &text,
 		const QString &description, const HbIcon &icon,
-		const HbDataFormModelItem *parent):
+		const HbDataFormModelItem *parent, HbTranslator *translator):
 		CpSettingFormEntryItemData(
 				itemDataHelper, text, description, icon, parent)
 {
 	OstTraceFunctionEntry0( DATETIMESETTINGSVIEW_DATETIMESETTINGSVIEW_ENTRY );
 	// Construct the timezone client.
+	mTranslator = translator;
 	mTimezoneClient = TimezoneClient::getInstance();
 	connect(
 			mTimezoneClient, SIGNAL(timechanged()),
@@ -95,7 +96,7 @@
 void DateTimeSettingsView::onLaunchView()
 {
 	OstTraceFunctionEntry0( DATETIMESETTINGSVIEW_ONLAUNCHVIEW_ENTRY );
-	ClockSettingsView *settingsView = new ClockSettingsView(this);
+	ClockSettingsView *settingsView = new ClockSettingsView(this, mTranslator, false);	
 	settingsView->loadSettingsView();
 	OstTraceFunctionExit0( DATETIMESETTINGSVIEW_ONLAUNCHVIEW_EXIT );
 }
--- a/clock/clockui/clocksettingsview/bwins/clocksettingsviewu.def	Mon Aug 09 18:30:52 2010 +0530
+++ b/clock/clockui/clocksettingsview/bwins/clocksettingsviewu.def	Wed Aug 25 14:02:13 2010 +0530
@@ -1,8 +1,8 @@
 EXPORTS
-	??0ClockSettingsView@@QAE@PAVQObject@@@Z @ 1 NONAME ; ClockSettingsView::ClockSettingsView(class QObject *)
-	??1ClockRegionalSettingsView@@UAE@XZ @ 2 NONAME ; ClockRegionalSettingsView::~ClockRegionalSettingsView(void)
-	?loadSettingsView@ClockSettingsView@@QAEXXZ @ 3 NONAME ; void ClockSettingsView::loadSettingsView(void)
-	??1ClockSettingsView@@UAE@XZ @ 4 NONAME ; ClockSettingsView::~ClockSettingsView(void)
+	??1ClockRegionalSettingsView@@UAE@XZ @ 1 NONAME ; ClockRegionalSettingsView::~ClockRegionalSettingsView(void)
+	?loadSettingsView@ClockSettingsView@@QAEXXZ @ 2 NONAME ; void ClockSettingsView::loadSettingsView(void)
+	??1ClockSettingsView@@UAE@XZ @ 3 NONAME ; ClockSettingsView::~ClockSettingsView(void)
+	??0ClockRegionalSettingsView@@QAE@PAVQObject@@_N@Z @ 4 NONAME ; ClockRegionalSettingsView::ClockRegionalSettingsView(class QObject *, bool)
 	?showView@ClockRegionalSettingsView@@QAEXXZ @ 5 NONAME ; void ClockRegionalSettingsView::showView(void)
-	??0ClockRegionalSettingsView@@QAE@PAVQObject@@@Z @ 6 NONAME ; ClockRegionalSettingsView::ClockRegionalSettingsView(class QObject *)
+	??0ClockSettingsView@@QAE@PAVQObject@@PAVHbTranslator@@_N@Z @ 6 NONAME ; ClockSettingsView::ClockSettingsView(class QObject *, class HbTranslator *, bool)
 
--- a/clock/clockui/clocksettingsview/data/clocksettingsview.qrc	Mon Aug 09 18:30:52 2010 +0530
+++ b/clock/clockui/clocksettingsview/data/clocksettingsview.qrc	Wed Aug 25 14:02:13 2010 +0530
@@ -3,4 +3,7 @@
 		<file alias="clocksettingsview.docml">xml/clocksettingsview.docml</file>
 		<file alias="clockregionalsettingsview.docml">xml/clockregionalsettingsview.docml</file>
 	</qresource>
+	<qresource prefix="/style">
+		<file alias="settingscustomitem.css">style/settingscustomitem.css</file>
+	</qresource>
 </RCC>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/clock/clockui/clocksettingsview/data/style/settingscustomitem.css	Wed Aug 25 14:02:13 2010 +0530
@@ -0,0 +1,22 @@
+SettingsCustomItem[!hasIcon][expandItem]:landscape
+{
+    layout:layout_portrait_without_icon;
+}
+
+SettingsCustomItem[hasIcon][expandItem]:landscape
+{
+    layout:layout_portrait_with_icon;
+}
+
+SettingsCustomItem[expandItem]::dataItem_Label:landscape
+{
+    size-policy-horizontal:preferred;
+}
+
+SettingsCustomItem[expandItem]::DataItem_ContentWidget:landscape
+{
+    top: -var(hb-param-margin-gene-top);
+    left:-var(hb-param-margin-gene-left);
+    right:var(hb-param-margin-gene-right);
+    bottom:var(hb-param-margin-gene-bottom);
+}
\ No newline at end of file
--- a/clock/clockui/clocksettingsview/eabi/clocksettingsviewu.def	Mon Aug 09 18:30:52 2010 +0530
+++ b/clock/clockui/clocksettingsview/eabi/clocksettingsviewu.def	Wed Aug 25 14:02:13 2010 +0530
@@ -1,13 +1,13 @@
 EXPORTS
 	_ZN17ClockSettingsView16loadSettingsViewEv @ 1 NONAME
-	_ZN17ClockSettingsViewC1EP7QObject @ 2 NONAME
-	_ZN17ClockSettingsViewC2EP7QObject @ 3 NONAME
+	_ZN17ClockSettingsViewC1EP7QObjectP12HbTranslatorb @ 2 NONAME
+	_ZN17ClockSettingsViewC2EP7QObjectP12HbTranslatorb @ 3 NONAME
 	_ZN17ClockSettingsViewD0Ev @ 4 NONAME
 	_ZN17ClockSettingsViewD1Ev @ 5 NONAME
 	_ZN17ClockSettingsViewD2Ev @ 6 NONAME
 	_ZN25ClockRegionalSettingsView8showViewEv @ 7 NONAME
-	_ZN25ClockRegionalSettingsViewC1EP7QObject @ 8 NONAME
-	_ZN25ClockRegionalSettingsViewC2EP7QObject @ 9 NONAME
+	_ZN25ClockRegionalSettingsViewC1EP7QObjectb @ 8 NONAME
+	_ZN25ClockRegionalSettingsViewC2EP7QObjectb @ 9 NONAME
 	_ZN25ClockRegionalSettingsViewD0Ev @ 10 NONAME
 	_ZN25ClockRegionalSettingsViewD1Ev @ 11 NONAME
 	_ZN25ClockRegionalSettingsViewD2Ev @ 12 NONAME
--- a/clock/clockui/clocksettingsview/inc/clockregionalsettingsview.h	Mon Aug 09 18:30:52 2010 +0530
+++ b/clock/clockui/clocksettingsview/inc/clockregionalsettingsview.h	Wed Aug 25 14:02:13 2010 +0530
@@ -45,7 +45,7 @@
 	Q_OBJECT
 
 public:
-	CLOCKSETTINGSVIEW_EXPORT ClockRegionalSettingsView(QObject *parent = 0);
+	CLOCKSETTINGSVIEW_EXPORT ClockRegionalSettingsView(QObject *parent = 0, bool launchedByClock = 1);
 	CLOCKSETTINGSVIEW_EXPORT virtual ~ClockRegionalSettingsView();
 
 public:
@@ -91,6 +91,7 @@
 	SettingsUtility *mSettingsUtility;
 	SettingsCustomItem *mCustomPrototype;
     HbTranslator *mTranslator;
+    bool mLauncedByClock;
 };
 
 #endif // CLOCKREGIONALSETTINGSVIEW_H
--- a/clock/clockui/clocksettingsview/inc/clocksettingsview.h	Mon Aug 09 18:30:52 2010 +0530
+++ b/clock/clockui/clocksettingsview/inc/clocksettingsview.h	Wed Aug 25 14:02:13 2010 +0530
@@ -46,7 +46,8 @@
 	Q_OBJECT
 
 public:
-	CLOCKSETTINGSVIEW_EXPORT ClockSettingsView(QObject *parent = 0);
+	CLOCKSETTINGSVIEW_EXPORT ClockSettingsView(QObject *parent = 0, HbTranslator *translator = 0,
+	        bool launchedByClock = 1);
 	CLOCKSETTINGSVIEW_EXPORT virtual ~ClockSettingsView();
 
 public:
@@ -93,6 +94,7 @@
 	XQSettingsKey *mAlarmSnoozeTimeKey;
 	QHash<int, int> mAlarmSnoozeTimeHash;
 	HbTranslator *mTranslator;
+	bool mLaunchedByClock;
 };
 
 #endif // CLOCKSETTINGSVIEW_H
--- a/clock/clockui/clocksettingsview/inc/settingscustomitem.h	Mon Aug 09 18:30:52 2010 +0530
+++ b/clock/clockui/clocksettingsview/inc/settingscustomitem.h	Wed Aug 25 14:02:13 2010 +0530
@@ -39,7 +39,7 @@
 	Q_OBJECT
 
 public:
-	SettingsCustomItem(QGraphicsItem *parent = 0);
+	SettingsCustomItem(QGraphicsItem *parent = 0, bool launchedByClock = 1);
 	virtual ~SettingsCustomItem();
 
 public:
@@ -78,6 +78,7 @@
 	SettingsUtility *mSettingsUtility;
 	ClockCitySelectionList *mCitySelectionList;
 	TimezoneClient *mTimezoneClient;
+	bool mLaunchedByClock;
 };
 
 #endif // SETTINGSCUSTOMITEM_H
--- a/clock/clockui/clocksettingsview/inc/settingsdatatypes.h	Mon Aug 09 18:30:52 2010 +0530
+++ b/clock/clockui/clocksettingsview/inc/settingsdatatypes.h	Wed Aug 25 14:02:13 2010 +0530
@@ -41,7 +41,8 @@
 	TimeItemOffset = 1,
 	DateItemOffset,
 	PlaceItemOffset,
-	RegionalItemOffset
+	RegionalItemOffset,
+	WorkdaysItemOffset
 };
 
 #endif // CLOCKSETTINGSDATATYPES_H
--- a/clock/clockui/clocksettingsview/src/clockregionalsettingsview.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/clock/clockui/clocksettingsview/src/clockregionalsettingsview.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -54,10 +54,11 @@
 /*!
 	Default constructor.
  */
-ClockRegionalSettingsView::ClockRegionalSettingsView(QObject *parent)
+ClockRegionalSettingsView::ClockRegionalSettingsView(QObject *parent, bool launchedByClock)
 :QObject(parent),
  mView(0),
- mLoader(0)
+ mLoader(0),
+ mLauncedByClock(launchedByClock)
 {
 	OstTraceFunctionEntry0( CLOCKREGIONALSETTINGSVIEW_CLOCKREGIONALSETTINGSVIEW_ENTRY );
 	// Construct the document loader.
@@ -142,6 +143,9 @@
 	createModel();
 
 	// Set the view as the current view.
+	if(!mLauncedByClock) {
+	    mView->setTitle(hbTrId("txt_clock_title_control_panel"));
+	}
 	HbMainWindow *window = hbInstance->allMainWindows().first();
 	window->addView(mView);
 	window->setCurrentView(mView);
@@ -437,7 +441,7 @@
 	
 	HbDataFormModelItem::DataItemType workdaysItemType =
 			static_cast<HbDataFormModelItem::DataItemType>
-			(HbDataFormModelItem::CustomItemBase + 50);
+			(HbDataFormModelItem::CustomItemBase + WorkdaysItemOffset);
 	item = new HbDataFormModelItem(workdaysItemType,
 			hbTrId("txt_clock_setlabel_workdays"));
 	mFormModel->appendDataFormItem(item);
--- a/clock/clockui/clocksettingsview/src/clocksettingsview.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/clock/clockui/clocksettingsview/src/clocksettingsview.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -56,14 +56,16 @@
 
 	\param parent The parent of type QGraphicsWidget.
  */
-ClockSettingsView::ClockSettingsView(QObject *parent)
-:QObject(parent)
+ClockSettingsView::ClockSettingsView(QObject *parent, HbTranslator *translator, bool launchedByClock)
+:QObject(parent), mTranslator(0), mLaunchedByClock(launchedByClock)
 {
 	OstTraceFunctionEntry0( CLOCKSETTINGSVIEW_CLOCKSETTINGSVIEW_ENTRY );
 	
 	// Load the translation file and install the editor specific translator
-    mTranslator = new HbTranslator("clocksettingsview");
-    mTranslator->loadCommon();
+    if(!translator) {
+        mTranslator = new HbTranslator("clocksettingsview");
+        mTranslator->loadCommon();   
+    }
 
 	// Construct the settings utility.
 	mSettingsUtility = new SettingsUtility();
@@ -292,6 +294,11 @@
 void ClockSettingsView::setupView()
 {
 	OstTraceFunctionEntry0( CLOCKSETTINGSVIEW_SETUPVIEW_ENTRY );
+	
+	if(!mLaunchedByClock) {
+	    mSettingsView->setTitle(hbTrId("txt_clock_title_control_panel"));
+	}
+	
 	HbMainWindow *window = hbInstance->allMainWindows().first();
 	window->addView(mSettingsView);
 	window->setCurrentView(mSettingsView);
@@ -309,7 +316,7 @@
 
 	// Create the custom prototype.
 	QList <HbAbstractViewItem*> prototypes = mSettingsForm->itemPrototypes();
-	SettingsCustomItem *customPrototype = new SettingsCustomItem(mSettingsForm);
+	SettingsCustomItem *customPrototype = new SettingsCustomItem(mSettingsForm, mLaunchedByClock);
 	prototypes.append(customPrototype);
 	mSettingsForm->setItemPrototypes(prototypes);
 
--- a/clock/clockui/clocksettingsview/src/settingscustomitem.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/clock/clockui/clocksettingsview/src/settingscustomitem.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -28,6 +28,7 @@
 #include <HbListWidget>
 #include <HbExtendedLocale>
 #include <HbListWidgetItem>
+#include <HbStyleLoader>
 
 // User includes
 #include "settingscustomitem.h"
@@ -54,14 +55,16 @@
 	\param parent The parent.
  */
 
-SettingsCustomItem::SettingsCustomItem(QGraphicsItem *parent)
-:HbDataFormViewItem(parent)
+SettingsCustomItem::SettingsCustomItem(QGraphicsItem *parent, bool launchedByClock)
+:HbDataFormViewItem(parent), mLaunchedByClock(launchedByClock)
 {
 	OstTraceFunctionEntry0( SETTINGSCUSTOMITEM_SETTINGSCUSTOMITEM_ENTRY );
 	// Construct the settignsutility.
 	mSettingsUtility = new SettingsUtility();
 	// Construct the timezone client.
 	mTimezoneClient = TimezoneClient::getInstance();
+	// Register for the css.
+	HbStyleLoader::registerFilePath(":/style/settingscustomitem.css");
 	OstTraceFunctionExit0( SETTINGSCUSTOMITEM_SETTINGSCUSTOMITEM_EXIT );
 }
 
@@ -71,7 +74,8 @@
 SettingsCustomItem::~SettingsCustomItem()
 {
 	OstTraceFunctionEntry0( DUP1_SETTINGSCUSTOMITEM_SETTINGSCUSTOMITEM_ENTRY );
-	// Nothing yet.
+	// Unregister the css.
+	HbStyleLoader::unregisterFilePath(":/style/settingscustomitem.css");
 	OstTraceFunctionExit0( DUP1_SETTINGSCUSTOMITEM_SETTINGSCUSTOMITEM_EXIT );
 }
 
@@ -185,6 +189,7 @@
 	switch (itemType) {
 		case (TimeItemOffset + HbDataFormModelItem::CustomItemBase):
 		{
+			setProperty("expandItem", false);
 			mTimeWidget = new HbPushButton(this);
 			connect(
 					mTimeWidget, SIGNAL(clicked()),
@@ -195,6 +200,7 @@
 
 		case (DateItemOffset + HbDataFormModelItem::CustomItemBase):
 		{
+			setProperty("expandItem", false);
 			mDateWidget = new HbPushButton(this);
 			connect(
 					mDateWidget, SIGNAL(clicked()),
@@ -205,6 +211,7 @@
 
 		case (PlaceItemOffset + HbDataFormModelItem::CustomItemBase):
 		{
+			setProperty("expandItem", false);
 			mPlaceWidget = new HbPushButton(this);
 			connect(
 					mPlaceWidget, SIGNAL(clicked()),
@@ -215,6 +222,7 @@
 
 		case (RegionalItemOffset + HbDataFormModelItem::CustomItemBase):
 		{
+			setProperty("expandItem", false);
 			mRegSettingsWidget = new HbPushButton(this);
 			connect(
 					mRegSettingsWidget, SIGNAL(clicked()),
@@ -223,8 +231,11 @@
 			return mRegSettingsWidget;
 		}
 
-		case (50 + HbDataFormModelItem::CustomItemBase):
+		case (WorkdaysItemOffset + HbDataFormModelItem::CustomItemBase):
 		{
+			// Set the property so that the custom item layout 
+			// will be the same for both portrait and landscape 
+			setProperty("expandItem", true);
 			mWorkdaysWidget = new HbListWidget(this);
 			mWorkdaysWidget->setSelectionMode(HbAbstractItemView::MultiSelection);
 			mWorkdaysWidget->setScrollDirections(0);
@@ -424,7 +435,8 @@
 {
 	OstTraceFunctionEntry0( SETTINGSCUSTOMITEM_LAUNCHREGSETTINGSVIEW_ENTRY );
 	ClockRegionalSettingsView *view =
-			new ClockRegionalSettingsView();
+			new ClockRegionalSettingsView(0, mLaunchedByClock);
+
 	connect(mTimezoneClient, SIGNAL(timechanged()),
           view, SLOT(updateWeekStartOn()));
 	view->showView();
--- a/clock/clockui/clocksettingsview/traces/clocksettingsviewTraces.h	Mon Aug 09 18:30:52 2010 +0530
+++ b/clock/clockui/clocksettingsview/traces/clocksettingsviewTraces.h	Wed Aug 25 14:02:13 2010 +0530
@@ -38,6 +38,8 @@
 #define CLOCKSETTINGSVIEW_HANDLECLOCKTYPECHANGED_EXIT 0x8a003f
 #define CLOCKSETTINGSVIEW_EVENTMONITOR_ENTRY 0x8a0040
 #define CLOCKSETTINGSVIEW_EVENTMONITOR_EXIT 0x8a0041
+#define CLOCKSETTINGSVIEW_GETVIEW_ENTRY 0x8a0064
+#define CLOCKSETTINGSVIEW_GETVIEW_EXIT 0x8a0065
 
 
 #endif
--- a/clock/clockui/clocksettingsview/traces/fixed_id.definitions	Mon Aug 09 18:30:52 2010 +0530
+++ b/clock/clockui/clocksettingsview/traces/fixed_id.definitions	Wed Aug 25 14:02:13 2010 +0530
@@ -35,6 +35,8 @@
 [TRACE]TRACE_FLOW[0x8A]_CLOCKSETTINGSVIEW_CREATEMODEL_EXIT=0x37
 [TRACE]TRACE_FLOW[0x8A]_CLOCKSETTINGSVIEW_EVENTMONITOR_ENTRY=0x40
 [TRACE]TRACE_FLOW[0x8A]_CLOCKSETTINGSVIEW_EVENTMONITOR_EXIT=0x41
+[TRACE]TRACE_FLOW[0x8A]_CLOCKSETTINGSVIEW_GETVIEW_ENTRY=0x64
+[TRACE]TRACE_FLOW[0x8A]_CLOCKSETTINGSVIEW_GETVIEW_EXIT=0x65
 [TRACE]TRACE_FLOW[0x8A]_CLOCKSETTINGSVIEW_HANDLEALARMSNOOZETIMECHANGED_ENTRY=0x3c
 [TRACE]TRACE_FLOW[0x8A]_CLOCKSETTINGSVIEW_HANDLEALARMSNOOZETIMECHANGED_EXIT=0x3d
 [TRACE]TRACE_FLOW[0x8A]_CLOCKSETTINGSVIEW_HANDLEAUTOTIMEUPDATECHANGE_ENTRY=0x3a
--- a/clock/clockui/clockviewmanager/src/clockviewmanager.cpp	Mon Aug 09 18:30:52 2010 +0530
+++ b/clock/clockui/clockviewmanager/src/clockviewmanager.cpp	Wed Aug 25 14:02:13 2010 +0530
@@ -161,6 +161,7 @@
 	// Find the main view.
 	mMainView = static_cast<ClockMainView *> (
 			docLoader->findWidget(CLOCK_MAIN_VIEW));
+	mMainView->setParent(this);
 	
 	// Disable animation effect on toolbar.
 	HbEffect::disable(mMainView->toolBar()->graphicsItem());
@@ -190,6 +191,7 @@
 	// Get the world list view.
 	mWorldClockView = static_cast<ClockWorldView *> (
 			docLoader->findWidget(CLOCK_WORLD_VIEW));
+	mWorldClockView->setParent(this);
 	
 	// Disable animation effect on toolbar.
 	HbEffect::disable(mWorldClockView->toolBar()->graphicsItem());
Binary file clock/conf/CI_clockapp.confml has changed