--- a/calendarui/views/dayview/src/calendaycontentscrollarea.cpp Mon Jul 12 02:32:28 2010 +0530
+++ b/calendarui/views/dayview/src/calendaycontentscrollarea.cpp Mon Jul 26 13:54:38 2010 +0530
@@ -44,12 +44,7 @@
CalenDayContentScrollArea::CalenDayContentScrollArea(QGraphicsItem *parent) :
HbScrollArea(parent), mPanDayDirection(ECalenPanNotSet), mIsMoving(false),
mMoveDirection(ECalenScrollNoDayChange)
-{
- // Set scroll settings
- setScrollDirections(Qt::Horizontal);
- setClampingStyle(StrictClamping);
- setHorizontalScrollBarPolicy(HbScrollArea::ScrollBarAlwaysOff);
-
+{
#ifdef CALENDAYVIEW_PANNING_ENABLED
grabGesture(Qt::PanGesture);
ungrabGesture(Qt::SwipeGesture);
@@ -61,6 +56,10 @@
// Get the width of content area and orientation of screen
mContentWidth = CalenDayUtils::instance()->contentWidth();
mOrientation = CalenDayUtils::instance()->orientation();
+
+ // Fix the width of scroll area
+ setMinimumWidth(mContentWidth);
+ setMaximumWidth(mContentWidth);
// Connect to main window's orientationChanged SIGNAL to handle orientation
// switching
@@ -402,7 +401,13 @@
// Update the width of content area
mContentWidth = CalenDayUtils::instance()->contentWidth();
mOrientation = orientation;
-
+
+ // Fix the width of scroll area
+ setMinimumWidth(mContentWidth);
+ setMaximumWidth(mContentWidth);
+
+ scrollToMiddleWidget();
+
// Reset flag related to moving
mPanDayDirection = ECalenPanNotSet;
mMoveDirection = ECalenScrollNoDayChange;