Diffstat (limited to 'libkdepim/kpimglobalprefs.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | libkdepim/kpimglobalprefs.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/libkdepim/kpimglobalprefs.cpp b/libkdepim/kpimglobalprefs.cpp index a09b278..873f0eb 100644 --- a/libkdepim/kpimglobalprefs.cpp +++ b/libkdepim/kpimglobalprefs.cpp | |||
@@ -55,16 +55,20 @@ KPimGlobalPrefs::KPimGlobalPrefs( const QString &name ) | |||
55 | KPrefs::setCurrentGroup("Locale"); | 55 | KPrefs::setCurrentGroup("Locale"); |
56 | addItemInt("PreferredLanguage",&mPreferredLanguage,0); | 56 | addItemInt("PreferredLanguage",&mPreferredLanguage,0); |
57 | addItemInt("PreferredTime",&mPreferredTime,0); | 57 | addItemInt("PreferredTime",&mPreferredTime,0); |
58 | addItemInt("PreferredDate",&mPreferredDate,0); | 58 | addItemInt("PreferredDate",&mPreferredDate,0); |
59 | addItemBool("WeekStartsOnSunday",&mWeekStartsOnSunday,false); | 59 | addItemBool("WeekStartsOnSunday",&mWeekStartsOnSunday,false); |
60 | addItemString("UserDateFormatLong", &mUserDateFormatLong, "%AK %d. %b %y"); | 60 | addItemString("UserDateFormatLong", &mUserDateFormatLong, "%AK %d. %b %y"); |
61 | addItemString("UserDateFormatShort", &mUserDateFormatShort, "%aK %d.%m.%y"); | 61 | addItemString("UserDateFormatShort", &mUserDateFormatShort, "%aK %d.%m.%y"); |
62 | 62 | ||
63 | KPrefs::setCurrentGroup("Colors"); | ||
64 | addItemColor("AlternateBGcolor",&mAlternateColor,KGlobalSettings::alternateBackgroundColor()); | ||
65 | |||
66 | |||
63 | KPrefs::setCurrentGroup("Time & Date"); | 67 | KPrefs::setCurrentGroup("Time & Date"); |
64 | 68 | ||
65 | addItemString("TimeZoneName",&mTimeZoneId, ("+01:00 Europe/Oslo(CET)") ); | 69 | addItemString("TimeZoneName",&mTimeZoneId, ("+01:00 Europe/Oslo(CET)") ); |
66 | addItemBool("UseDaylightsaving",&mUseDaylightsaving,true); | 70 | addItemBool("UseDaylightsaving",&mUseDaylightsaving,true); |
67 | addItemBool("TimeZoneAdd30min",&mTimeZoneAdd30min,false); | 71 | addItemBool("TimeZoneAdd30min",&mTimeZoneAdd30min,false); |
68 | addItemInt("DaylightsavingStart",&mDaylightsavingStart,90); | 72 | addItemInt("DaylightsavingStart",&mDaylightsavingStart,90); |
69 | addItemInt("DaylightsavingEnd",&mDaylightsavingEnd,304); | 73 | addItemInt("DaylightsavingEnd",&mDaylightsavingEnd,304); |
70 | 74 | ||
@@ -183,16 +187,17 @@ void KPimGlobalPrefs::setGlobalConfig() | |||
183 | QString dummy = mUserDateFormatLong; | 187 | QString dummy = mUserDateFormatLong; |
184 | KGlobal::locale()->setDateFormat(dummy.replace( QRegExp("K"), QString(",") )); | 188 | KGlobal::locale()->setDateFormat(dummy.replace( QRegExp("K"), QString(",") )); |
185 | dummy = mUserDateFormatShort; | 189 | dummy = mUserDateFormatShort; |
186 | KGlobal::locale()->setDateFormatShort(dummy.replace( QRegExp("K"), QString(",") )); | 190 | KGlobal::locale()->setDateFormatShort(dummy.replace( QRegExp("K"), QString(",") )); |
187 | KGlobal::locale()->setDaylightSaving( mUseDaylightsaving, | 191 | KGlobal::locale()->setDaylightSaving( mUseDaylightsaving, |
188 | mDaylightsavingStart, | 192 | mDaylightsavingStart, |
189 | mDaylightsavingEnd ); | 193 | mDaylightsavingEnd ); |
190 | KGlobal::locale()->setTimezone( mTimeZoneId, mTimeZoneAdd30min ); | 194 | KGlobal::locale()->setTimezone( mTimeZoneId, mTimeZoneAdd30min ); |
195 | KGlobalSettings::setAlternateBackgroundColor(mAlternateColor); | ||
191 | 196 | ||
192 | } | 197 | } |
193 | KPimGlobalPrefs::~KPimGlobalPrefs() | 198 | KPimGlobalPrefs::~KPimGlobalPrefs() |
194 | { | 199 | { |
195 | if (sInstance == this) | 200 | if (sInstance == this) |
196 | sInstance = staticDeleterGP.setObject(0); | 201 | sInstance = staticDeleterGP.setObject(0); |
197 | else | 202 | else |
198 | qDebug("Whats this? Error in KPimGlobalPrefs::~KPimGlobalPrefs() ?"); | 203 | qDebug("Whats this? Error in KPimGlobalPrefs::~KPimGlobalPrefs() ?"); |