-rw-r--r-- | korganizer/koagendaitem.cpp | 10 | ||||
-rw-r--r-- | korganizer/koprefs.cpp | 1 | ||||
-rw-r--r-- | korganizer/koprefs.h | 1 | ||||
-rw-r--r-- | korganizer/koprefsdialog.cpp | 6 |
4 files changed, 17 insertions, 1 deletions
diff --git a/korganizer/koagendaitem.cpp b/korganizer/koagendaitem.cpp index ee9f39a..a05c60e 100644 --- a/korganizer/koagendaitem.cpp +++ b/korganizer/koagendaitem.cpp | |||
@@ -96,6 +96,14 @@ void KOAgendaItem::init ( Incidence *incidence, QDate qd ) | |||
96 | if (cat.isEmpty()) { | 96 | if (cat.isEmpty()) { |
97 | mBackgroundColor =KOPrefs::instance()->mEventColor; | 97 | if ( (incidence->type() == "Todo") &&((static_cast<Todo*>(incidence))->isCompleted()) ) |
98 | mBackgroundColor =KOPrefs::instance()->mTodoDoneColor; | ||
99 | else | ||
100 | mBackgroundColor =KOPrefs::instance()->mEventColor; | ||
98 | } else { | 101 | } else { |
99 | mBackgroundColor = *KOPrefs::instance()->categoryColor(cat); | 102 | mBackgroundColor = *KOPrefs::instance()->categoryColor(cat); |
103 | if ( (incidence->type() == "Todo") &&((static_cast<Todo*>(incidence))->isCompleted()) ) { | ||
104 | if ( mBackgroundColor == KOPrefs::instance()->mEventColor ) | ||
105 | mBackgroundColor =KOPrefs::instance()->mTodoDoneColor; | ||
106 | } | ||
100 | } | 107 | } |
108 | |||
101 | } | 109 | } |
diff --git a/korganizer/koprefs.cpp b/korganizer/koprefs.cpp index 32cc291..0548f14 100644 --- a/korganizer/koprefs.cpp +++ b/korganizer/koprefs.cpp | |||
@@ -199,2 +199,3 @@ KOPrefs::KOPrefs() : | |||
199 | addItemColor("Event Color",&mEventColor,mDefaultCategoryColor); | 199 | addItemColor("Event Color",&mEventColor,mDefaultCategoryColor); |
200 | addItemColor("Todo done Color",&mTodoDoneColor,QColor(111,255,115) ); | ||
200 | addItemColor("Agenda Background Color",&mAgendaBgColor,defaultAgendaBgColor); | 201 | addItemColor("Agenda Background Color",&mAgendaBgColor,defaultAgendaBgColor); |
diff --git a/korganizer/koprefs.h b/korganizer/koprefs.h index b3acda7..8b849fa 100644 --- a/korganizer/koprefs.h +++ b/korganizer/koprefs.h | |||
@@ -125,2 +125,3 @@ class KOPrefs : public KPimPrefs | |||
125 | QColor mEventColor; | 125 | QColor mEventColor; |
126 | QColor mTodoDoneColor; | ||
126 | QColor mAgendaBgColor; | 127 | QColor mAgendaBgColor; |
diff --git a/korganizer/koprefsdialog.cpp b/korganizer/koprefsdialog.cpp index 1b24f56..580dff2 100644 --- a/korganizer/koprefsdialog.cpp +++ b/korganizer/koprefsdialog.cpp | |||
@@ -1178,2 +1178,8 @@ void KOPrefsDialog::setupColorsTab() | |||
1178 | topLayout->addWidget(eventColor->button(),ii++,1); | 1178 | topLayout->addWidget(eventColor->button(),ii++,1); |
1179 | eventColor = | ||
1180 | addWidColor(i18n("Default todo done color:"), | ||
1181 | &(KOPrefs::instance()->mTodoDoneColor),topFrame); | ||
1182 | topLayout->addWidget(eventColor->label(),ii,0); | ||
1183 | topLayout->addWidget(eventColor->button(),ii++,1); | ||
1184 | |||
1179 | 1185 | ||