summaryrefslogtreecommitdiffabout
path: root/korganizer
authorzautrix <zautrix>2005-02-01 23:46:24 (UTC)
committer zautrix <zautrix>2005-02-01 23:46:24 (UTC)
commit9ecfd0660e36b6b8dd7401f0edb16dd3d6f03289 (patch) (side-by-side diff)
treed80eb20b97ab401b4e9e34f25b65030fb2c0b035 /korganizer
parentafa94abe147d23e09a14a81e47d04d4a3d5670c3 (diff)
downloadkdepimpi-9ecfd0660e36b6b8dd7401f0edb16dd3d6f03289.zip
kdepimpi-9ecfd0660e36b6b8dd7401f0edb16dd3d6f03289.tar.gz
kdepimpi-9ecfd0660e36b6b8dd7401f0edb16dd3d6f03289.tar.bz2
text
Diffstat (limited to 'korganizer') (more/less context) (ignore whitespace changes)
-rw-r--r--korganizer/komonthview.cpp11
1 files changed, 5 insertions, 6 deletions
diff --git a/korganizer/komonthview.cpp b/korganizer/komonthview.cpp
index 9888566..6294b98 100644
--- a/korganizer/komonthview.cpp
+++ b/korganizer/komonthview.cpp
@@ -687,17 +687,13 @@ void MonthViewCell::select()
}
void MonthViewCell::resizeEvent ( QResizeEvent * )
{
if ( !mMonthView->isUpdatePossible() )
return;
-#ifndef DESKTOP_VERSION
- if ( !isVisible() ){
- return;
- }
-#endif
+
int size = height() - mLabel->height() - 2;
if ( size > 0 )
mItemList->verticalScrollBar()->setMaximumHeight( size );
size = width() - mLabel->width() -2;
if ( size > 0 )
mItemList->horizontalScrollBar()->setMaximumWidth( size );
@@ -838,12 +834,14 @@ KOMonthView::KOMonthView(Calendar *calendar, QWidget *parent, const char *name)
KOMonthView::~KOMonthView()
{
delete mContextMenu;
}
void KOMonthView::switchView()
{
+ if ( selectedCell( ) )
+ selectedCell()->deselect();
mShowWeekView = !mShowWeekView;
KOPrefs::instance()->mMonthViewWeek = mShowWeekView;
emit showNavigator( !mShowWeekView );
computeLayout();
updateConfig();
}
@@ -1156,17 +1154,18 @@ void KOMonthView::computeLayoutWeek()
w = colWid;
h = dayLabelHei ;
for ( i = 0; i < 7; i++) {
if ( i && !( i % daysToShow) && i < 6) {
y += hei/(5-daysToShow);
x = 0;
+ w = colWid;
}
if ( i == daysToShow-colModulo )
++w;
if ( i >= 5 ) {
- mDayLabels[i]->setGeometry( x+weeklabelwid,y,w/2,h);
+ mDayLabels[i]->setGeometry( x+weeklabelwid,y,w/2+1,h);
x -= w/2 ;
}
else
mDayLabels[i]->setGeometry( x+weeklabelwid,y,w,h);
x += w;
}