author | zautrix <zautrix> | 2004-09-22 02:03:15 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2004-09-22 02:03:15 (UTC) |
commit | 633522024e48efc423155a04b71083a03696211d (patch) (side-by-side diff) | |
tree | c383ee8fa3489351450b948eb83a42b504752131 | |
parent | ed2feaa9f7e2064e5b26ff678a25eb79ceae599b (diff) | |
download | kdepimpi-633522024e48efc423155a04b71083a03696211d.zip kdepimpi-633522024e48efc423155a04b71083a03696211d.tar.gz kdepimpi-633522024e48efc423155a04b71083a03696211d.tar.bz2 |
global prefs integrated in kopi amd ompi
-rw-r--r-- | kmicromail/kmicromailE.pro | 4 | ||||
-rw-r--r-- | kmicromail/koprefsdialog.cpp | 16 | ||||
-rw-r--r-- | kmicromail/koprefsdialog.h | 3 | ||||
-rw-r--r-- | korganizer/koprefsdialog.cpp | 12 | ||||
-rw-r--r-- | korganizer/koprefsdialog.h | 3 |
5 files changed, 34 insertions, 4 deletions
diff --git a/kmicromail/kmicromailE.pro b/kmicromail/kmicromailE.pro index 0d6cf86..75ba92f 100644 --- a/kmicromail/kmicromailE.pro +++ b/kmicromail/kmicromailE.pro @@ -53,10 +53,10 @@ INTERFACES = editaccountsui.ui \ selectstoreui.ui \ nntpgroupsui.ui -INCLUDEPATH += . $(KDEPIMDIR) $(KDEPIMDIR)/qtcompat $(KDEPIMDIR)/microkde $(KDEPIMDIR)/microkde/kdecore libetpan/include $(KDEPIMDIR)/microkde/kdeui $(QPEDIR)/include -LIBS += -L$(QPEDIR)/lib -lkmicromailwrapper -lqpe -lkmicrolibetpan -lmicrokde -lmicroqtcompat -lssl -lcrypto -ljpeg -lmicrokde -lmicroqtcompat -lmicrokabc -lmicrokcal -lmicrokdepim +INCLUDEPATH += . $(KDEPIMDIR) $(KDEPIMDIR)/libkdepim $(KDEPIMDIR)/qtcompat $(KDEPIMDIR)/microkde $(KDEPIMDIR)/microkde/kdecore libetpan/include $(KDEPIMDIR)/microkde/kdeui $(QPEDIR)/include +LIBS += -L$(QPEDIR)/lib -lkmicromailwrapper -lqpe -lkmicrolibetpan -lmicrokde -lmicroqtcompat -lssl -lcrypto -ljpeg -lmicroqtcompat -lmicrokdepim LIBS += $(QTOPIALIB) #LIBS += -lqtopia #next line for Zaurus only #LIBS += -luuid diff --git a/kmicromail/koprefsdialog.cpp b/kmicromail/koprefsdialog.cpp index 7d7bd2a..598d12f 100644 --- a/kmicromail/koprefsdialog.cpp +++ b/kmicromail/koprefsdialog.cpp @@ -59,15 +59,17 @@ #include "koprefs.h" #include "koprefsdialog.h" +//#include <kprefswidget.h> KOPrefsDialog::KOPrefsDialog(QWidget *parent, char *name, bool modal) : KPrefsDialog(KOPrefs::instance(),parent,name,true) { setCaption( i18n("Settings - some need a restart (nr)")); + setupGlobalTab(); setupMainTab(); setupMailTab();; setupFontsTab(); readConfig(); @@ -89,13 +91,22 @@ KOPrefsDialog::KOPrefsDialog(QWidget *parent, char *name, bool modal) : //setupGroupAutomationTab(); #endif } +#include "kpimglobalprefs.h" KOPrefsDialog::~KOPrefsDialog() { } +void KOPrefsDialog::setupGlobalTab() +{ + QFrame *topFrame = addPage(i18n("Global"),0,0); + kdelibcfg = new KDEPIMConfigWidget( KPimGlobalPrefs::instance(), topFrame, "KCMKdeLibConfig" ); + QVBoxLayout *topLayout = new QVBoxLayout(topFrame); + topLayout->addWidget( kdelibcfg ); + +} void KOPrefsDialog::setupMainTab() { QFrame *topFrame = addPage(i18n("General"),0,0); @@ -180,17 +191,18 @@ void KOPrefsDialog::setupFontsTab() } void KOPrefsDialog::usrReadConfig() { - qDebug("read "); + mNameEdit->setText(KOPrefs::instance()->mName); mEmailEdit->setText(KOPrefs::instance()->mEmail); + kdelibcfg->readConfig(); } void KOPrefsDialog::usrWriteConfig() { - qDebug("write "); KOPrefs::instance()->mName = mNameEdit->text(); KOPrefs::instance()->mEmail = mEmailEdit->text(); + kdelibcfg->writeConfig(); } diff --git a/kmicromail/koprefsdialog.h b/kmicromail/koprefsdialog.h index 4b6bd4b..615574b 100644 --- a/kmicromail/koprefsdialog.h +++ b/kmicromail/koprefsdialog.h @@ -31,8 +31,9 @@ #include <kdialogbase.h> #include <libkdepim/kprefsdialog.h> #include <libkdepim/kdateedit.h> +#include <kcmconfigs/kdepimconfigwidget.h> class KColorButton; class QSpinBox; class QSlider; @@ -55,11 +56,13 @@ protected: void usrReadConfig(); void usrWriteConfig(); void setupMainTab(); + void setupGlobalTab(); void setupMailTab(); void setupFontsTab(); private: + KDEPIMConfigWidget* kdelibcfg; QLineEdit *mNameEdit; QLineEdit *mEmailEdit; QLabel *mNameLabel; QLabel *mEmailLabel; diff --git a/korganizer/koprefsdialog.cpp b/korganizer/koprefsdialog.cpp index 1c30faa..7dafcd8 100644 --- a/korganizer/koprefsdialog.cpp +++ b/korganizer/koprefsdialog.cpp @@ -66,8 +66,9 @@ #include "koprefs.h" #include "koprefsdialog.h" +#include "kpimglobalprefs.h" KOPrefsDialog::KOPrefsDialog(QWidget *parent, char *name, bool modal) : KPrefsDialog(KOPrefs::instance(),parent,name,true) @@ -77,8 +78,9 @@ KOPrefsDialog::KOPrefsDialog(QWidget *parent, char *name, bool modal) : mCategoryDict.setAutoDelete(true); KGlobal::locale()->insertCatalogue("timezones"); + setupGlobalTab(); setupMainTab(); setupLocaleTab(); setupTimeZoneTab(); setupTimeTab(); @@ -96,9 +98,17 @@ KOPrefsDialog::KOPrefsDialog(QWidget *parent, char *name, bool modal) : KOPrefsDialog::~KOPrefsDialog() { } +void KOPrefsDialog::setupGlobalTab() +{ + QFrame *topFrame = addPage(i18n("Global"),0,0); + kdelibcfg = new KDEPIMConfigWidget( KPimGlobalPrefs::instance(), topFrame, "KCMKdeLibConfig" ); + QVBoxLayout *topLayout = new QVBoxLayout(topFrame); + topLayout->addWidget( kdelibcfg ); + +} void KOPrefsDialog::setupLocaleDateTab() { QFrame *topFrame = addPage(i18n("Date Format"),0,0); QGridLayout *topLayout = new QGridLayout(topFrame,3,2); @@ -1320,8 +1330,9 @@ void KOPrefsDialog::setCombo(QComboBox *combo, const QString & text, } void KOPrefsDialog::usrReadConfig() { + kdelibcfg->readConfig(); mNameEdit->setText(KOPrefs::instance()->fullName()); mEmailEdit->setText(KOPrefs::instance()->email()); mAutoSaveIntervalSpin->setValue(KOPrefs::instance()->mAutoSaveInterval); @@ -1369,8 +1380,9 @@ void KOPrefsDialog::usrReadConfig() void KOPrefsDialog::usrWriteConfig() { + kdelibcfg->writeConfig(); // KOPrefs::instance()->mRemoteIP = mRemoteIPEdit->text(); //KOPrefs::instance()->mRemoteUser = mRemoteUser->text(); //KOPrefs::instance()->mRemotePassWd = mRemotePassWd->text(); //KOPrefs::instance()->mRemoteFile= mRemoteFile->text(); diff --git a/korganizer/koprefsdialog.h b/korganizer/koprefsdialog.h index 83dc1eb..e20969a 100644 --- a/korganizer/koprefsdialog.h +++ b/korganizer/koprefsdialog.h @@ -31,8 +31,9 @@ #include <kdialogbase.h> #include <libkdepim/kprefsdialog.h> #include <libkdepim/kdateedit.h> +#include <kcmconfigs/kdepimconfigwidget.h> class KColorButton; class QSpinBox; class QSlider; @@ -78,8 +79,9 @@ class KOPrefsDialog : public KPrefsDialog protected: void usrReadConfig(); void usrWriteConfig(); + void setupGlobalTab(); void setupMainTab(); void setupTimeTab(); void setupTimeZoneTab(); @@ -98,8 +100,9 @@ class KOPrefsDialog : public KPrefsDialog void setCombo(QComboBox *combo,const QString & text, const QStringList *tags = 0); private: + KDEPIMConfigWidget* kdelibcfg; KPrefsDialogWidBool *mEnableGroupScheduling; KPrefsDialogWidBool *mEnableProjectView; QFrame *mPrinterTab; |