author | zautrix <zautrix> | 2004-10-08 23:38:07 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2004-10-08 23:38:07 (UTC) |
commit | 07fdef2c2ea1153d39d7114b3d5bd4abc4f4c861 (patch) (side-by-side diff) | |
tree | 03d0e5d20e607e035e17fcdabd6bce789069f41e /libkdepim/kpimglobalprefs.cpp | |
parent | 44169895703beb3e8b1551a313d2d341bf742905 (diff) | |
download | kdepimpi-07fdef2c2ea1153d39d7114b3d5bd4abc4f4c861.zip kdepimpi-07fdef2c2ea1153d39d7114b3d5bd4abc4f4c861.tar.gz kdepimpi-07fdef2c2ea1153d39d7114b3d5bd4abc4f4c861.tar.bz2 |
some bugfixes
Diffstat (limited to 'libkdepim/kpimglobalprefs.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | libkdepim/kpimglobalprefs.cpp | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/libkdepim/kpimglobalprefs.cpp b/libkdepim/kpimglobalprefs.cpp index b71e18d..5081b26 100644 --- a/libkdepim/kpimglobalprefs.cpp +++ b/libkdepim/kpimglobalprefs.cpp @@ -53,27 +53,24 @@ KPimGlobalPrefs::KPimGlobalPrefs( const QString &name ) //addItemBool("QuickSavingWOUnicode",&mUseQuicksave,false); // addItemBool("ShortDateInViewer",&mShortDateInViewer,false); addItemString("UserDateFormatLong", &mUserDateFormatLong, "%A %d %b %y"); addItemString("UserDateFormatShort", &mUserDateFormatShort, "%aK %d.%m.%y"); KPrefs::setCurrentGroup("Time & Date"); addItemString("TimeZoneName",&mTimeZoneId,i18n ("+01:00 Europe/Oslo(CET)") ); addItemBool("UseDaylightsaving",&mUseDaylightsaving,true); addItemInt("DaylightsavingStart",&mDaylightsavingStart,90); addItemInt("DaylightsavingEnd",&mDaylightsavingEnd,304); - - - KPrefs::setCurrentGroup( "ExternalApplications" ); addItemInt( "EmailChannelType", &mEmailClient, OMPI_EMC ); addItemString( "EmailChannel", &mEmailOtherChannel, "" ); addItemString( "EmailChannelMessage", &mEmailOtherMessage, "" ); addItemString( "EmailChannelParameters", &mEmailOtherMessageParameters, "" ); addItemString( "EmailChannelMessage2", &mEmailOtherMessage2, "" ); addItemString( "EmailChannelParameters2", &mEmailOtherMessageParameters2, "" ); addItemInt( "PhoneChannelType", &mPhoneClient, KPPI_PHC ); addItemString( "PhoneChannel", &mPhoneOtherChannel, "" ); addItemString( "PhoneChannelMessage", &mPhoneOtherMessage, "" ); @@ -90,51 +87,52 @@ KPimGlobalPrefs::KPimGlobalPrefs( const QString &name ) addItemString( "SMSChannelParameters", &mSMSOtherMessageParameters, "" ); addItemInt( "PagerChannelType", &mPagerClient, NONE_PAC ); addItemString( "PagerChannel", &mPagerOtherChannel, "" ); addItemString( "PagerChannelMessage", &mPagerOtherMessage, "" ); addItemString( "PagerChannelParameters", &mPagerOtherMessageParameters, "" ); addItemInt( "SIPChannelType", &mSipClient, NONE_SIC ); addItemString( "SIPChannel", &mSipOtherChannel, "" ); addItemString( "SIPChannelMessage", &mSipOtherMessage, "" ); addItemString( "SIPChannelParameters", &mSipOtherMessageParameters, "" ); - KPrefs::setCurrentGroup( "PhoneAccess" ); addItemString("Ex2PhoneDevice",&mEx2PhoneDevice,"/dev/ircomm"); addItemString("Ex2PhoneConnection",&mEx2PhoneConnection,"irda"); addItemString("Ex2PhoneModel",&mEx2PhoneModel,"6310i"); - } + void KPimGlobalPrefs::setGlobalConfig() { KGlobal::locale()->setHore24Format( !mPreferredTime ); KGlobal::locale()->setWeekStartMonday( !mWeekStartsOnSunday ); KGlobal::locale()->setIntDateFormat( (KLocale::IntDateFormat)mPreferredDate ); KGlobal::locale()->setLanguage( mPreferredLanguage ); QString dummy = mUserDateFormatLong; KGlobal::locale()->setDateFormat(dummy.replace( QRegExp("K"), QString(",") )); dummy = mUserDateFormatShort; KGlobal::locale()->setDateFormatShort(dummy.replace( QRegExp("K"), QString(",") )); KGlobal::locale()->setDaylightSaving( mUseDaylightsaving, mDaylightsavingStart, mDaylightsavingEnd ); KGlobal::locale()->setTimezone( mTimeZoneId ); } KPimGlobalPrefs::~KPimGlobalPrefs() -{ +{ + //qDebug("KPimGlobalPrefs::~KPimGlobalPrefs() "); + writeConfig(); } KPimGlobalPrefs *KPimGlobalPrefs::instance() { if ( !sInstance ) { sInstance = staticDeleter.setObject( new KPimGlobalPrefs() ); sInstance->readConfig(); } return sInstance; } |