author | zautrix <zautrix> | 2005-06-27 21:06:01 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2005-06-27 21:06:01 (UTC) |
commit | 386f48c2011e49c7c145bad7754a725cabc25dd5 (patch) (side-by-side diff) | |
tree | 104009f871e81468f2b4b5ba779b12c25a409c32 /korganizer/komonthview.cpp | |
parent | bf664c505e66f54dd03c3518386fdeab43108e56 (diff) | |
download | kdepimpi-386f48c2011e49c7c145bad7754a725cabc25dd5.zip kdepimpi-386f48c2011e49c7c145bad7754a725cabc25dd5.tar.gz kdepimpi-386f48c2011e49c7c145bad7754a725cabc25dd5.tar.bz2 |
mont fix
-rw-r--r-- | korganizer/komonthview.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/korganizer/komonthview.cpp b/korganizer/komonthview.cpp index aeb3974..64b0e95 100644 --- a/korganizer/komonthview.cpp +++ b/korganizer/komonthview.cpp @@ -314,52 +314,51 @@ bool MonthViewItem::setHighlighted( Incidence * inc ) mDisplayHightlighted = true; return true; } else { if ( !mDisplayHightlighted ) return false; mDisplayHightlighted = false; return true; } return false; } void MonthViewItem::paint(QPainter *p) { if ( mblockRepaint || !mIncidence ) { return; } #if QT_VERSION >= 0x030000 bool sel = isSelected(); #else bool sel = selected(); #endif int heihei = height( listBox () ); int x = 1; if (KOPrefs::instance()->mMonthViewUsesCategoryColor || mDisplayHightlighted || sel ) { - if ( mDisplayHightlighted ) - sel = true; + p->setBackgroundColor( palette().color( QPalette::Normal, \ - sel ? QColorGroup::Highlight : QColorGroup::Background ) ); + sel ||mDisplayHightlighted ? QColorGroup::Highlight : QColorGroup::Background ) ); p->eraseRect( 0, 0, listBox()->maxItemWidth(), heihei ); } //int y = 3;//(height() - mRecurPixmap.height()) /2; int size = PIXMAP_SIZE; if ( QApplication::desktop()->width() < 300 ) size = 3; int y = (heihei - size -1 ) /2; if ( mIncidence->calID() > 1 ) { p->fillRect ( x, y-2,size,size+4, KOPrefs::instance()->defaultColor( mIncidence->calID() ) ); p->drawRect ( x, y-2,size,size+4); x += size + 1; } if ( KOPrefs::instance()->mMonthShowIcons ) { if ( mInfo ) { p->fillRect ( x, y,size,size, Qt::darkGreen ); x += size + 1; } if ( mRecur ) { p->fillRect ( x, y,size,size, Qt::blue ); x += size + 1; } if ( mAlarm ) { |