summaryrefslogtreecommitdiffabout
path: root/korganizer/kodaymatrix.cpp
Side-by-side diff
Diffstat (limited to 'korganizer/kodaymatrix.cpp') (more/less context) (show whitespace changes)
-rw-r--r--korganizer/kodaymatrix.cpp17
1 files changed, 13 insertions, 4 deletions
diff --git a/korganizer/kodaymatrix.cpp b/korganizer/kodaymatrix.cpp
index d543aaf..dfc6af7 100644
--- a/korganizer/kodaymatrix.cpp
+++ b/korganizer/kodaymatrix.cpp
@@ -112,2 +112,3 @@ KODayMatrix::KODayMatrix(QWidget *parent, Calendar* calendar, QDate date, const
{
+ mRedrawNeeded = true;
mKODaymatrixWhatsThis = new KODaymatrixWhatsThis(this);
@@ -388,2 +389,3 @@ void KODayMatrix::updateViewTimed()
}
+ mRedrawNeeded = true;
if ( ! mPendingUpdateBeforeRepaint )
@@ -422,2 +424,3 @@ void KODayMatrix::updateView(QDate actdate)
recalculateToday();
+ mRedrawNeeded = true;
}
@@ -430,3 +433,3 @@ void KODayMatrix::updateView(QDate actdate)
//updateViewTimed();
- mUpdateTimer->start( 20 );
+ mUpdateTimer->start( 50 );
#else
@@ -680,3 +683,7 @@ void KODayMatrix::paintEvent(QPaintEvent * pevent)
myPix.resize(size() );
+ mRedrawNeeded = true;
}
+
+ if ( mRedrawNeeded ) {
+ //qDebug("REDRAW ");
QPainter p(&myPix);
@@ -929,5 +936,7 @@ void KODayMatrix::paintEvent(QPaintEvent * pevent)
}
- int off = 0;//xyOff;
- bitBlt (this, off, off, &myPix, 0 ,0,width(), height() ,CopyROP);
- //qDebug("ffffffffff %d ", off);
+ } else {
+ //qDebug("NO redraw ");
+ }
+ bitBlt (this, 0, 0, &myPix, 0 ,0,width(), height() ,CopyROP);
+ mRedrawNeeded = false;
}