summaryrefslogtreecommitdiffabout
path: root/libkdepim
authorzautrix <zautrix>2004-09-22 03:08:05 (UTC)
committer zautrix <zautrix>2004-09-22 03:08:05 (UTC)
commitd63eac7a612a9724705bc58ad98c65c6ac052d07 (patch) (unidiff)
treedc584a0ddcbd5f828ea36b86b6af640e46e137f2 /libkdepim
parent633522024e48efc423155a04b71083a03696211d (diff)
downloadkdepimpi-d63eac7a612a9724705bc58ad98c65c6ac052d07.zip
kdepimpi-d63eac7a612a9724705bc58ad98c65c6ac052d07.tar.gz
kdepimpi-d63eac7a612a9724705bc58ad98c65c6ac052d07.tar.bz2
connected global config
Diffstat (limited to 'libkdepim') (more/less context) (ignore whitespace changes)
-rw-r--r--libkdepim/kcmconfigs/kdepimconfigwidget.cpp2
-rw-r--r--libkdepim/kpimglobalprefs.cpp17
-rw-r--r--libkdepim/kpimglobalprefs.h4
3 files changed, 19 insertions, 4 deletions
diff --git a/libkdepim/kcmconfigs/kdepimconfigwidget.cpp b/libkdepim/kcmconfigs/kdepimconfigwidget.cpp
index 00a07d9..2819ab1 100644
--- a/libkdepim/kcmconfigs/kdepimconfigwidget.cpp
+++ b/libkdepim/kcmconfigs/kdepimconfigwidget.cpp
@@ -745,5 +745,5 @@ void KDEPIMConfigWidget::usrWriteConfig()
745 //release the cache that other views can access the changed values instantanious 745 //release the cache that other views can access the changed values instantanious
746 ExternalAppHandler::instance()->loadConfig(); 746 ExternalAppHandler::instance()->loadConfig();
747 747 KPimGlobalPrefs::instance()->setGlobalConfig();
748} 748}
749 749
diff --git a/libkdepim/kpimglobalprefs.cpp b/libkdepim/kpimglobalprefs.cpp
index 12a503d..a896a0f 100644
--- a/libkdepim/kpimglobalprefs.cpp
+++ b/libkdepim/kpimglobalprefs.cpp
@@ -101,4 +101,21 @@ KPimGlobalPrefs::KPimGlobalPrefs( const QString &name )
101} 101}
102 102
103void KPimGlobalPrefs::setGlobalConfig()
104{
105
106 KGlobal::locale()->setHore24Format( !mPreferredTime );
107 KGlobal::locale()->setWeekStartMonday( !mWeekStartsOnSunday );
108 KGlobal::locale()->setIntDateFormat( (KLocale::IntDateFormat)mPreferredDate );
109 KGlobal::locale()->setLanguage( mPreferredLanguage );
110 QString dummy = mUserDateFormatLong;
111 KGlobal::locale()->setDateFormat(dummy.replace( QRegExp("K"), QString(",") ));
112 dummy = mUserDateFormatShort;
113 KGlobal::locale()->setDateFormatShort(dummy.replace( QRegExp("K"), QString(",") ));
114 KGlobal::locale()->setDaylightSaving( mUseDaylightsaving,
115 mDaylightsavingStart,
116 mDaylightsavingEnd );
117 KGlobal::locale()->setTimezone( mTimeZoneId );
118
119}
103KPimGlobalPrefs::~KPimGlobalPrefs() 120KPimGlobalPrefs::~KPimGlobalPrefs()
104{ 121{
diff --git a/libkdepim/kpimglobalprefs.h b/libkdepim/kpimglobalprefs.h
index dad78e6..84ba689 100644
--- a/libkdepim/kpimglobalprefs.h
+++ b/libkdepim/kpimglobalprefs.h
@@ -38,4 +38,5 @@ class KPimGlobalPrefs : public KPrefs
38 public: 38 public:
39 39
40 void setGlobalConfig();
40 static KPimGlobalPrefs *instance(); 41 static KPimGlobalPrefs *instance();
41 42
@@ -97,7 +98,4 @@ class KPimGlobalPrefs : public KPrefs
97 int mDaylightsavingEnd; 98 int mDaylightsavingEnd;
98 99
99
100
101
102 int mEmailClient; 100 int mEmailClient;
103 QString mEmailOtherChannel; 101 QString mEmailOtherChannel;