summaryrefslogtreecommitdiffabout
path: root/korganizer/koagendaitem.cpp
Side-by-side diff
Diffstat (limited to 'korganizer/koagendaitem.cpp') (more/less context) (show whitespace changes)
-rw-r--r--korganizer/koagendaitem.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/korganizer/koagendaitem.cpp b/korganizer/koagendaitem.cpp
index 6965ba7..62281d4 100644
--- a/korganizer/koagendaitem.cpp
+++ b/korganizer/koagendaitem.cpp
@@ -406,63 +406,63 @@ void KOAgendaItem::paintMe( bool selected, QPainter* paint )
}
}
QRect dr;
paint->drawText ( x, yy, w, h, align, mDisplayedText, -1, &dr );
if ( mIncidence->cancelled() ){
if ( ! small ) {
QFontMetrics fm ( paint->font() );
paint->drawLine(dr.left(), yy+fm.height()/2, dr.right()-2, yy+fm.height()/2);
}
}
pa.end();
}
void KOAgendaItem::resizePixmap( int w , int h )
{
paintPix()->resize( w, h );
paintPixSel()->resize( w, h );
}
QPixmap * KOAgendaItem::paintPix()
{
static QPixmap* mPaintPix = 0;
if ( ! mPaintPix )
- mPaintPix = new QPixmap();
+ mPaintPix = new QPixmap(1,1);
return mPaintPix ;
}
QPixmap * KOAgendaItem::paintPixAllday()
{
static QPixmap* mPaintPixA = 0;
if ( ! mPaintPixA )
- mPaintPixA = new QPixmap();
+ mPaintPixA = new QPixmap(1,1);
return mPaintPixA ;
}
QPixmap * KOAgendaItem::paintPixSel()
{
static QPixmap* mPaintPixSel = 0;
if ( ! mPaintPixSel )
- mPaintPixSel = new QPixmap();
+ mPaintPixSel = new QPixmap(1,1);
return mPaintPixSel ;
}
void KOAgendaItem::paintEvent ( QPaintEvent *e )
{
if ( globalFlagBlockAgendaItemPaint )
return;
if ( globalFlagBlockAgenda > 0 && globalFlagBlockAgenda < 5 )
return;
int yy;
if ( mAllDay )
yy = y();
else
yy = mCellYTop * ( height() / cellHeight() );
int xx = x();
if ( xPaintCoord != xx || yPaintCoord != yy ||
wPaintCoord != width() || hPaintCoord != height()) {
xPaintCoord= xx;
yPaintCoord = yy;
wPaintCoord = width();
hPaintCoord = height();
globalFlagBlockAgendaItemUpdate = 0;
paintMe( mSelected );
//qDebug("calling paintMe ");