author | zautrix <zautrix> | 2004-09-22 02:03:15 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2004-09-22 02:03:15 (UTC) |
commit | 633522024e48efc423155a04b71083a03696211d (patch) (unidiff) | |
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 | 18 | ||||
-rw-r--r-- | kmicromail/koprefsdialog.h | 3 | ||||
-rw-r--r-- | korganizer/koprefsdialog.cpp | 14 | ||||
-rw-r--r-- | korganizer/koprefsdialog.h | 3 |
5 files changed, 36 insertions, 6 deletions
diff --git a/kmicromail/kmicromailE.pro b/kmicromail/kmicromailE.pro index 0d6cf86..75ba92f 100644 --- a/kmicromail/kmicromailE.pro +++ b/kmicromail/kmicromailE.pro | |||
@@ -33,38 +33,38 @@ SOURCES = main.cpp \ | |||
33 | settingsdialog.cpp \ | 33 | settingsdialog.cpp \ |
34 | statuswidget.cpp \ | 34 | statuswidget.cpp \ |
35 | newmaildir.cpp \ | 35 | newmaildir.cpp \ |
36 | selectstore.cpp \ | 36 | selectstore.cpp \ |
37 | selectsmtp.cpp \ | 37 | selectsmtp.cpp \ |
38 | nntpgroups.cpp \ | 38 | nntpgroups.cpp \ |
39 | koprefs.cpp\ | 39 | koprefs.cpp\ |
40 | koprefsdialog.cpp\ | 40 | koprefsdialog.cpp\ |
41 | nntpgroupsdlg.cpp | 41 | nntpgroupsdlg.cpp |
42 | 42 | ||
43 | INTERFACES = editaccountsui.ui \ | 43 | INTERFACES = editaccountsui.ui \ |
44 | selectmailtypeui.ui \ | 44 | selectmailtypeui.ui \ |
45 | imapconfigui.ui \ | 45 | imapconfigui.ui \ |
46 | pop3configui.ui \ | 46 | pop3configui.ui \ |
47 | nntpconfigui.ui \ | 47 | nntpconfigui.ui \ |
48 | smtpconfigui.ui \ | 48 | smtpconfigui.ui \ |
49 | composemailui.ui \ | 49 | composemailui.ui \ |
50 | settingsdialogui.ui \ | 50 | settingsdialogui.ui \ |
51 | statuswidgetui.ui \ | 51 | statuswidgetui.ui \ |
52 | newmaildirui.ui \ | 52 | newmaildirui.ui \ |
53 | selectstoreui.ui \ | 53 | selectstoreui.ui \ |
54 | nntpgroupsui.ui | 54 | nntpgroupsui.ui |
55 | 55 | ||
56 | 56 | ||
57 | INCLUDEPATH += . $(KDEPIMDIR) $(KDEPIMDIR)/qtcompat $(KDEPIMDIR)/microkde $(KDEPIMDIR)/microkde/kdecore libetpan/include $(KDEPIMDIR)/microkde/kdeui $(QPEDIR)/include | 57 | INCLUDEPATH += . $(KDEPIMDIR) $(KDEPIMDIR)/libkdepim $(KDEPIMDIR)/qtcompat $(KDEPIMDIR)/microkde $(KDEPIMDIR)/microkde/kdecore libetpan/include $(KDEPIMDIR)/microkde/kdeui $(QPEDIR)/include |
58 | LIBS += -L$(QPEDIR)/lib -lkmicromailwrapper -lqpe -lkmicrolibetpan -lmicrokde -lmicroqtcompat -lssl -lcrypto -ljpeg -lmicrokde -lmicroqtcompat -lmicrokabc -lmicrokcal -lmicrokdepim | 58 | LIBS += -L$(QPEDIR)/lib -lkmicromailwrapper -lqpe -lkmicrolibetpan -lmicrokde -lmicroqtcompat -lssl -lcrypto -ljpeg -lmicroqtcompat -lmicrokdepim |
59 | LIBS += $(QTOPIALIB) | 59 | LIBS += $(QTOPIALIB) |
60 | #LIBS += -lqtopia | 60 | #LIBS += -lqtopia |
61 | #next line for Zaurus only | 61 | #next line for Zaurus only |
62 | #LIBS += -luuid | 62 | #LIBS += -luuid |
63 | 63 | ||
64 | # | 64 | # |
65 | OBJECTS_DIR = obj/$(PLATFORM) | 65 | OBJECTS_DIR = obj/$(PLATFORM) |
66 | MOC_DIR = moc/$(PLATFORM) | 66 | MOC_DIR = moc/$(PLATFORM) |
67 | DESTDIR=$(QPEDIR)/bin | 67 | DESTDIR=$(QPEDIR)/bin |
68 | TARGET = ompi | 68 | TARGET = ompi |
69 | 69 | ||
70 | 70 | ||
diff --git a/kmicromail/koprefsdialog.cpp b/kmicromail/koprefsdialog.cpp index 7d7bd2a..598d12f 100644 --- a/kmicromail/koprefsdialog.cpp +++ b/kmicromail/koprefsdialog.cpp | |||
@@ -39,83 +39,94 @@ | |||
39 | #include <qcheckbox.h> | 39 | #include <qcheckbox.h> |
40 | #include <qradiobutton.h> | 40 | #include <qradiobutton.h> |
41 | #include <qpushbutton.h> | 41 | #include <qpushbutton.h> |
42 | #include <qstrlist.h> | 42 | #include <qstrlist.h> |
43 | #include <qapplication.h> | 43 | #include <qapplication.h> |
44 | 44 | ||
45 | #include <kcolorbutton.h> | 45 | #include <kcolorbutton.h> |
46 | #include <kdebug.h> | 46 | #include <kdebug.h> |
47 | #include <klocale.h> | 47 | #include <klocale.h> |
48 | #include <kglobal.h> | 48 | #include <kglobal.h> |
49 | #include <kfontdialog.h> | 49 | #include <kfontdialog.h> |
50 | #include <kfiledialog.h> | 50 | #include <kfiledialog.h> |
51 | #include <kmessagebox.h> | 51 | #include <kmessagebox.h> |
52 | #include <kcolordialog.h> | 52 | #include <kcolordialog.h> |
53 | #include <kiconloader.h> | 53 | #include <kiconloader.h> |
54 | #include <kemailsettings.h> | 54 | #include <kemailsettings.h> |
55 | #include <kstandarddirs.h> | 55 | #include <kstandarddirs.h> |
56 | 56 | ||
57 | #include <klineedit.h> | 57 | #include <klineedit.h> |
58 | 58 | ||
59 | 59 | ||
60 | #include "koprefs.h" | 60 | #include "koprefs.h" |
61 | 61 | ||
62 | #include "koprefsdialog.h" | 62 | #include "koprefsdialog.h" |
63 | //#include <kprefswidget.h> | ||
63 | 64 | ||
64 | 65 | ||
65 | KOPrefsDialog::KOPrefsDialog(QWidget *parent, char *name, bool modal) : | 66 | KOPrefsDialog::KOPrefsDialog(QWidget *parent, char *name, bool modal) : |
66 | KPrefsDialog(KOPrefs::instance(),parent,name,true) | 67 | KPrefsDialog(KOPrefs::instance(),parent,name,true) |
67 | { | 68 | { |
68 | 69 | ||
69 | setCaption( i18n("Settings - some need a restart (nr)")); | 70 | setCaption( i18n("Settings - some need a restart (nr)")); |
71 | setupGlobalTab(); | ||
70 | setupMainTab(); | 72 | setupMainTab(); |
71 | setupMailTab();; | 73 | setupMailTab();; |
72 | setupFontsTab(); | 74 | setupFontsTab(); |
73 | readConfig(); | 75 | readConfig(); |
74 | 76 | ||
75 | #if 0 | 77 | #if 0 |
76 | 78 | ||
77 | setupMainTab(); | 79 | setupMainTab(); |
78 | setupLocaleTab(); | 80 | setupLocaleTab(); |
79 | setupTimeZoneTab(); | 81 | setupTimeZoneTab(); |
80 | setupTimeTab(); | 82 | setupTimeTab(); |
81 | setupLocaleDateTab(); | 83 | setupLocaleDateTab(); |
82 | setupFontsTab(); | 84 | setupFontsTab(); |
83 | setupColorsTab(); | 85 | setupColorsTab(); |
84 | setupViewsTab(); | 86 | setupViewsTab(); |
85 | //setupSyncTab(); | 87 | //setupSyncTab(); |
86 | //setupSyncAlgTab(); | 88 | //setupSyncAlgTab(); |
87 | //setupPrinterTab(); | 89 | //setupPrinterTab(); |
88 | //setupGroupSchedulingTab(); | 90 | //setupGroupSchedulingTab(); |
89 | //setupGroupAutomationTab(); | 91 | //setupGroupAutomationTab(); |
90 | #endif | 92 | #endif |
91 | } | 93 | } |
92 | 94 | ||
95 | #include "kpimglobalprefs.h" | ||
93 | 96 | ||
94 | KOPrefsDialog::~KOPrefsDialog() | 97 | KOPrefsDialog::~KOPrefsDialog() |
95 | { | 98 | { |
96 | } | 99 | } |
97 | 100 | void KOPrefsDialog::setupGlobalTab() | |
101 | { | ||
102 | QFrame *topFrame = addPage(i18n("Global"),0,0); | ||
103 | kdelibcfg = new KDEPIMConfigWidget( KPimGlobalPrefs::instance(), topFrame, "KCMKdeLibConfig" ); | ||
104 | QVBoxLayout *topLayout = new QVBoxLayout(topFrame); | ||
105 | topLayout->addWidget( kdelibcfg ); | ||
106 | |||
107 | |||
108 | } | ||
98 | void KOPrefsDialog::setupMainTab() | 109 | void KOPrefsDialog::setupMainTab() |
99 | { | 110 | { |
100 | QFrame *topFrame = addPage(i18n("General"),0,0); | 111 | QFrame *topFrame = addPage(i18n("General"),0,0); |
101 | 112 | ||
102 | QGridLayout *topLayout = new QGridLayout(topFrame,6,2); | 113 | QGridLayout *topLayout = new QGridLayout(topFrame,6,2); |
103 | topLayout->setSpacing(spacingHint()); | 114 | topLayout->setSpacing(spacingHint()); |
104 | topLayout->setMargin(marginHint()); | 115 | topLayout->setMargin(marginHint()); |
105 | 116 | ||
106 | 117 | ||
107 | mNameEdit = new QLineEdit(topFrame); | 118 | mNameEdit = new QLineEdit(topFrame); |
108 | mNameLabel = new QLabel(mNameEdit, i18n("Full &name:"), topFrame); | 119 | mNameLabel = new QLabel(mNameEdit, i18n("Full &name:"), topFrame); |
109 | topLayout->addWidget(mNameLabel,0,0); | 120 | topLayout->addWidget(mNameLabel,0,0); |
110 | topLayout->addWidget(mNameEdit,0,1); | 121 | topLayout->addWidget(mNameEdit,0,1); |
111 | 122 | ||
112 | mEmailEdit = new QLineEdit(topFrame); | 123 | mEmailEdit = new QLineEdit(topFrame); |
113 | mEmailLabel = new QLabel(mEmailEdit, i18n("E&mail address:"),topFrame); | 124 | mEmailLabel = new QLabel(mEmailEdit, i18n("E&mail address:"),topFrame); |
114 | topLayout->addWidget(mEmailLabel,1,0); | 125 | topLayout->addWidget(mEmailLabel,1,0); |
115 | topLayout->addWidget(mEmailEdit,1,1); | 126 | topLayout->addWidget(mEmailEdit,1,1); |
116 | QLabel *lab = new QLabel( i18n("HINT: Separate multiple\neMail addresses by \";\""), topFrame); | 127 | QLabel *lab = new QLabel( i18n("HINT: Separate multiple\neMail addresses by \";\""), topFrame); |
117 | topLayout->addMultiCellWidget(lab,2,2,0,1); | 128 | topLayout->addMultiCellWidget(lab,2,2,0,1); |
118 | KPrefsDialogWidBool* ttt = addWidBool(i18n("Ignore above settings and\nuse KA/Pi \"Who am I\" instead!"), | 129 | KPrefsDialogWidBool* ttt = addWidBool(i18n("Ignore above settings and\nuse KA/Pi \"Who am I\" instead!"), |
119 | &(KOPrefs::instance()->mUseKapi),topFrame); | 130 | &(KOPrefs::instance()->mUseKapi),topFrame); |
120 | topLayout->addMultiCellWidget(ttt->checkBox(),3,3,0,1); | 131 | topLayout->addMultiCellWidget(ttt->checkBox(),3,3,0,1); |
121 | } | 132 | } |
@@ -160,57 +171,58 @@ void KOPrefsDialog::setupFontsTab() | |||
160 | 171 | ||
161 | 172 | ||
162 | timeLabelsFont = | 173 | timeLabelsFont = |
163 | addWidFont(i18n("Dear Mr."),i18n("Compose mail:"), | 174 | addWidFont(i18n("Dear Mr."),i18n("Compose mail:"), |
164 | &(KOPrefs::instance()->mComposeFont),topFrame); | 175 | &(KOPrefs::instance()->mComposeFont),topFrame); |
165 | topLayout->addWidget(timeLabelsFont->label(),i,0); | 176 | topLayout->addWidget(timeLabelsFont->label(),i,0); |
166 | topLayout->addWidget(timeLabelsFont->preview(),i,1); | 177 | topLayout->addWidget(timeLabelsFont->preview(),i,1); |
167 | topLayout->addWidget(timeLabelsFont->button(),i,2); | 178 | topLayout->addWidget(timeLabelsFont->button(),i,2); |
168 | ++i; | 179 | ++i; |
169 | 180 | ||
170 | KPrefsDialogWidFont *timeBarFont = | 181 | KPrefsDialogWidFont *timeBarFont = |
171 | addWidFont(i18n("Hello"),i18n("Read mail:"), | 182 | addWidFont(i18n("Hello"),i18n("Read mail:"), |
172 | &(KOPrefs::instance()->mReadFont),topFrame); | 183 | &(KOPrefs::instance()->mReadFont),topFrame); |
173 | topLayout->addWidget(timeBarFont->label(),i,0); | 184 | topLayout->addWidget(timeBarFont->label(),i,0); |
174 | topLayout->addWidget(timeBarFont->preview(),i,1); | 185 | topLayout->addWidget(timeBarFont->preview(),i,1); |
175 | topLayout->addWidget(timeBarFont->button(),i,2); | 186 | topLayout->addWidget(timeBarFont->button(),i,2); |
176 | ++i; | 187 | ++i; |
177 | 188 | ||
178 | topLayout->setColStretch(1,1); | 189 | topLayout->setColStretch(1,1); |
179 | topLayout->setRowStretch(4,1); | 190 | topLayout->setRowStretch(4,1); |
180 | 191 | ||
181 | } | 192 | } |
182 | void KOPrefsDialog::usrReadConfig() | 193 | void KOPrefsDialog::usrReadConfig() |
183 | { | 194 | { |
184 | qDebug("read "); | 195 | |
185 | mNameEdit->setText(KOPrefs::instance()->mName); | 196 | mNameEdit->setText(KOPrefs::instance()->mName); |
186 | mEmailEdit->setText(KOPrefs::instance()->mEmail); | 197 | mEmailEdit->setText(KOPrefs::instance()->mEmail); |
198 | kdelibcfg->readConfig(); | ||
187 | } | 199 | } |
188 | void KOPrefsDialog::usrWriteConfig() | 200 | void KOPrefsDialog::usrWriteConfig() |
189 | { | 201 | { |
190 | qDebug("write "); | ||
191 | KOPrefs::instance()->mName = mNameEdit->text(); | 202 | KOPrefs::instance()->mName = mNameEdit->text(); |
192 | KOPrefs::instance()->mEmail = mEmailEdit->text(); | 203 | KOPrefs::instance()->mEmail = mEmailEdit->text(); |
204 | kdelibcfg->writeConfig(); | ||
193 | 205 | ||
194 | 206 | ||
195 | } | 207 | } |
196 | 208 | ||
197 | #if 0 | 209 | #if 0 |
198 | void KOPrefsDialog::setupLocaleDateTab() | 210 | void KOPrefsDialog::setupLocaleDateTab() |
199 | { | 211 | { |
200 | QFrame *topFrame = addPage(i18n("Date Format"),0,0); | 212 | QFrame *topFrame = addPage(i18n("Date Format"),0,0); |
201 | QGridLayout *topLayout = new QGridLayout(topFrame,3,2); | 213 | QGridLayout *topLayout = new QGridLayout(topFrame,3,2); |
202 | topLayout->setSpacing(spacingHint()); | 214 | topLayout->setSpacing(spacingHint()); |
203 | topLayout->setMargin(marginHint()); | 215 | topLayout->setMargin(marginHint()); |
204 | int iii = 0; | 216 | int iii = 0; |
205 | 217 | ||
206 | 218 | ||
207 | KPrefsWidRadios *syncPrefsGroup = | 219 | KPrefsWidRadios *syncPrefsGroup = |
208 | addWidRadios(i18n("Date Format:"),&(KOPrefs::instance()->mPreferredDate),topFrame); | 220 | addWidRadios(i18n("Date Format:"),&(KOPrefs::instance()->mPreferredDate),topFrame); |
209 | QString format; | 221 | QString format; |
210 | if ( QApplication::desktop()->width() < 480 ) | 222 | if ( QApplication::desktop()->width() < 480 ) |
211 | format = "(%d.%m.%Y)"; | 223 | format = "(%d.%m.%Y)"; |
212 | else | 224 | else |
213 | format = "(%d.%m.%Y|%A %d %B %Y)"; | 225 | format = "(%d.%m.%Y|%A %d %B %Y)"; |
214 | syncPrefsGroup->addRadio(i18n("24.03.2004 "+format)); | 226 | syncPrefsGroup->addRadio(i18n("24.03.2004 "+format)); |
215 | if ( QApplication::desktop()->width() < 480 ) | 227 | if ( QApplication::desktop()->width() < 480 ) |
216 | format = "(%m.%d.%Y)"; | 228 | format = "(%m.%d.%Y)"; |
diff --git a/kmicromail/koprefsdialog.h b/kmicromail/koprefsdialog.h index 4b6bd4b..615574b 100644 --- a/kmicromail/koprefsdialog.h +++ b/kmicromail/koprefsdialog.h | |||
@@ -11,75 +11,78 @@ | |||
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of | 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
13 | GNU General Public License for more details. | 13 | GNU General Public License for more details. |
14 | 14 | ||
15 | You should have received a copy of the GNU General Public License | 15 | You should have received a copy of the GNU General Public License |
16 | along with this program; if not, write to the Free Software | 16 | along with this program; if not, write to the Free Software |
17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | 17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
18 | 18 | ||
19 | As a special exception, permission is given to link this program | 19 | As a special exception, permission is given to link this program |
20 | with any edition of Qt, and distribute the resulting executable, | 20 | with any edition of Qt, and distribute the resulting executable, |
21 | without including the source code for Qt in the source distribution. | 21 | without including the source code for Qt in the source distribution. |
22 | */ | 22 | */ |
23 | #ifndef _KOPREFSDIALOG_H | 23 | #ifndef _KOPREFSDIALOG_H |
24 | #define _KOPREFSDIALOG_H | 24 | #define _KOPREFSDIALOG_H |
25 | 25 | ||
26 | #include <qframe.h> | 26 | #include <qframe.h> |
27 | #include <qdict.h> | 27 | #include <qdict.h> |
28 | #include <qcolor.h> | 28 | #include <qcolor.h> |
29 | #include <qlistview.h> | 29 | #include <qlistview.h> |
30 | 30 | ||
31 | #include <kdialogbase.h> | 31 | #include <kdialogbase.h> |
32 | 32 | ||
33 | #include <libkdepim/kprefsdialog.h> | 33 | #include <libkdepim/kprefsdialog.h> |
34 | #include <libkdepim/kdateedit.h> | 34 | #include <libkdepim/kdateedit.h> |
35 | #include <kcmconfigs/kdepimconfigwidget.h> | ||
35 | 36 | ||
36 | class KColorButton; | 37 | class KColorButton; |
37 | class QSpinBox; | 38 | class QSpinBox; |
38 | class QSlider; | 39 | class QSlider; |
39 | class KURLRequester; | 40 | class KURLRequester; |
40 | class QComboBox; | 41 | class QComboBox; |
41 | class QLineEdit; | 42 | class QLineEdit; |
42 | class QStringList; | 43 | class QStringList; |
43 | 44 | ||
44 | /** Dialog to change the korganizer configuration. | 45 | /** Dialog to change the korganizer configuration. |
45 | */ | 46 | */ |
46 | class KOPrefsDialog : public KPrefsDialog | 47 | class KOPrefsDialog : public KPrefsDialog |
47 | { | 48 | { |
48 | Q_OBJECT | 49 | Q_OBJECT |
49 | public: | 50 | public: |
50 | /** Initialize dialog and pages */ | 51 | /** Initialize dialog and pages */ |
51 | KOPrefsDialog(QWidget *parent=0,char *name=0,bool modal=false); | 52 | KOPrefsDialog(QWidget *parent=0,char *name=0,bool modal=false); |
52 | ~KOPrefsDialog(); | 53 | ~KOPrefsDialog(); |
53 | 54 | ||
54 | protected: | 55 | protected: |
55 | void usrReadConfig(); | 56 | void usrReadConfig(); |
56 | void usrWriteConfig(); | 57 | void usrWriteConfig(); |
57 | 58 | ||
58 | void setupMainTab(); | 59 | void setupMainTab(); |
60 | void setupGlobalTab(); | ||
59 | void setupMailTab(); | 61 | void setupMailTab(); |
60 | void setupFontsTab(); | 62 | void setupFontsTab(); |
61 | private: | 63 | private: |
64 | KDEPIMConfigWidget* kdelibcfg; | ||
62 | QLineEdit *mNameEdit; | 65 | QLineEdit *mNameEdit; |
63 | QLineEdit *mEmailEdit; | 66 | QLineEdit *mEmailEdit; |
64 | QLabel *mNameLabel; | 67 | QLabel *mNameLabel; |
65 | QLabel *mEmailLabel; | 68 | QLabel *mEmailLabel; |
66 | #if 0 | 69 | #if 0 |
67 | /* | 70 | /* |
68 | public slots: | 71 | public slots: |
69 | void showPrinterTab(); | 72 | void showPrinterTab(); |
70 | 73 | ||
71 | 74 | ||
72 | void updateCategories(); | 75 | void updateCategories(); |
73 | void showSyncPage(); | 76 | void showSyncPage(); |
74 | protected slots: | 77 | protected slots: |
75 | void selectSoundFile(); | 78 | void selectSoundFile(); |
76 | void setCategoryColor(); | 79 | void setCategoryColor(); |
77 | void updateCategoryColor(); | 80 | void updateCategoryColor(); |
78 | void updateTimezoneOffset( int ); | 81 | void updateTimezoneOffset( int ); |
79 | 82 | ||
80 | 83 | ||
81 | void warningExperimental(bool on); | 84 | void warningExperimental(bool on); |
82 | void warningGroupScheduling(); | 85 | void warningGroupScheduling(); |
83 | void warningProjectView(); | 86 | void warningProjectView(); |
84 | 87 | ||
85 | void toggleEmailSettings(bool); | 88 | void toggleEmailSettings(bool); |
diff --git a/korganizer/koprefsdialog.cpp b/korganizer/koprefsdialog.cpp index 1c30faa..7dafcd8 100644 --- a/korganizer/koprefsdialog.cpp +++ b/korganizer/koprefsdialog.cpp | |||
@@ -46,79 +46,89 @@ | |||
46 | #include <kdebug.h> | 46 | #include <kdebug.h> |
47 | #include <klocale.h> | 47 | #include <klocale.h> |
48 | #include <kglobal.h> | 48 | #include <kglobal.h> |
49 | #include <kfontdialog.h> | 49 | #include <kfontdialog.h> |
50 | #include <kfiledialog.h> | 50 | #include <kfiledialog.h> |
51 | #include <kmessagebox.h> | 51 | #include <kmessagebox.h> |
52 | #include <kcolordialog.h> | 52 | #include <kcolordialog.h> |
53 | #include <kiconloader.h> | 53 | #include <kiconloader.h> |
54 | #include <kemailsettings.h> | 54 | #include <kemailsettings.h> |
55 | #include <kstandarddirs.h> | 55 | #include <kstandarddirs.h> |
56 | 56 | ||
57 | #include <kurlrequester.h> | 57 | #include <kurlrequester.h> |
58 | #include <klineedit.h> | 58 | #include <klineedit.h> |
59 | 59 | ||
60 | #if defined(USE_SOLARIS) | 60 | #if defined(USE_SOLARIS) |
61 | #include <sys/param.h> | 61 | #include <sys/param.h> |
62 | 62 | ||
63 | #define ZONEINFODIR "/usr/share/lib/zoneinfo" | 63 | #define ZONEINFODIR "/usr/share/lib/zoneinfo" |
64 | #define INITFILE "/etc/default/init" | 64 | #define INITFILE "/etc/default/init" |
65 | #endif | 65 | #endif |
66 | 66 | ||
67 | #include "koprefs.h" | 67 | #include "koprefs.h" |
68 | 68 | ||
69 | #include "koprefsdialog.h" | 69 | #include "koprefsdialog.h" |
70 | #include "kpimglobalprefs.h" | ||
70 | 71 | ||
71 | 72 | ||
72 | KOPrefsDialog::KOPrefsDialog(QWidget *parent, char *name, bool modal) : | 73 | KOPrefsDialog::KOPrefsDialog(QWidget *parent, char *name, bool modal) : |
73 | KPrefsDialog(KOPrefs::instance(),parent,name,true) | 74 | KPrefsDialog(KOPrefs::instance(),parent,name,true) |
74 | { | 75 | { |
75 | 76 | ||
76 | setCaption( i18n("Preferences - some settings need a restart (nr)")); | 77 | setCaption( i18n("Preferences - some settings need a restart (nr)")); |
77 | mCategoryDict.setAutoDelete(true); | 78 | mCategoryDict.setAutoDelete(true); |
78 | 79 | ||
79 | KGlobal::locale()->insertCatalogue("timezones"); | 80 | KGlobal::locale()->insertCatalogue("timezones"); |
80 | 81 | ||
82 | setupGlobalTab(); | ||
81 | setupMainTab(); | 83 | setupMainTab(); |
82 | setupLocaleTab(); | 84 | setupLocaleTab(); |
83 | setupTimeZoneTab(); | 85 | setupTimeZoneTab(); |
84 | setupTimeTab(); | 86 | setupTimeTab(); |
85 | setupLocaleDateTab(); | 87 | setupLocaleDateTab(); |
86 | setupFontsTab(); | 88 | setupFontsTab(); |
87 | setupColorsTab(); | 89 | setupColorsTab(); |
88 | setupViewsTab(); | 90 | setupViewsTab(); |
89 | //setupSyncTab(); | 91 | //setupSyncTab(); |
90 | //setupSyncAlgTab(); | 92 | //setupSyncAlgTab(); |
91 | //setupPrinterTab(); | 93 | //setupPrinterTab(); |
92 | //setupGroupSchedulingTab(); | 94 | //setupGroupSchedulingTab(); |
93 | //setupGroupAutomationTab(); | 95 | //setupGroupAutomationTab(); |
94 | } | 96 | } |
95 | 97 | ||
96 | 98 | ||
97 | KOPrefsDialog::~KOPrefsDialog() | 99 | KOPrefsDialog::~KOPrefsDialog() |
98 | { | 100 | { |
99 | } | 101 | } |
100 | 102 | void KOPrefsDialog::setupGlobalTab() | |
103 | { | ||
104 | QFrame *topFrame = addPage(i18n("Global"),0,0); | ||
105 | kdelibcfg = new KDEPIMConfigWidget( KPimGlobalPrefs::instance(), topFrame, "KCMKdeLibConfig" ); | ||
106 | QVBoxLayout *topLayout = new QVBoxLayout(topFrame); | ||
107 | topLayout->addWidget( kdelibcfg ); | ||
108 | |||
109 | |||
110 | } | ||
101 | void KOPrefsDialog::setupLocaleDateTab() | 111 | void KOPrefsDialog::setupLocaleDateTab() |
102 | { | 112 | { |
103 | QFrame *topFrame = addPage(i18n("Date Format"),0,0); | 113 | QFrame *topFrame = addPage(i18n("Date Format"),0,0); |
104 | QGridLayout *topLayout = new QGridLayout(topFrame,3,2); | 114 | QGridLayout *topLayout = new QGridLayout(topFrame,3,2); |
105 | topLayout->setSpacing(spacingHint()); | 115 | topLayout->setSpacing(spacingHint()); |
106 | topLayout->setMargin(marginHint()); | 116 | topLayout->setMargin(marginHint()); |
107 | int iii = 0; | 117 | int iii = 0; |
108 | 118 | ||
109 | 119 | ||
110 | KPrefsDialogWidRadios *syncPrefsGroup = | 120 | KPrefsDialogWidRadios *syncPrefsGroup = |
111 | addWidRadios(i18n("Date Format:"),&(KOPrefs::instance()->mPreferredDate),topFrame); | 121 | addWidRadios(i18n("Date Format:"),&(KOPrefs::instance()->mPreferredDate),topFrame); |
112 | QString format; | 122 | QString format; |
113 | if ( QApplication::desktop()->width() < 480 ) | 123 | if ( QApplication::desktop()->width() < 480 ) |
114 | format = "(%d.%m.%Y)"; | 124 | format = "(%d.%m.%Y)"; |
115 | else | 125 | else |
116 | format = "(%d.%m.%Y|%A %d %B %Y)"; | 126 | format = "(%d.%m.%Y|%A %d %B %Y)"; |
117 | syncPrefsGroup->addRadio(i18n("24.03.2004 "+format)); | 127 | syncPrefsGroup->addRadio(i18n("24.03.2004 "+format)); |
118 | if ( QApplication::desktop()->width() < 480 ) | 128 | if ( QApplication::desktop()->width() < 480 ) |
119 | format = "(%m.%d.%Y)"; | 129 | format = "(%m.%d.%Y)"; |
120 | else | 130 | else |
121 | format = "(%m.%d.%Y|%A %B %d %Y)"; | 131 | format = "(%m.%d.%Y|%A %B %d %Y)"; |
122 | syncPrefsGroup->addRadio(i18n("03.24.2004 "+format)); | 132 | syncPrefsGroup->addRadio(i18n("03.24.2004 "+format)); |
123 | if ( QApplication::desktop()->width() < 480 ) | 133 | if ( QApplication::desktop()->width() < 480 ) |
124 | format = "(%Y-%m-%d)"; | 134 | format = "(%Y-%m-%d)"; |
@@ -1300,48 +1310,49 @@ void KOPrefsDialog::setupGroupAutomationTab() | |||
1300 | void KOPrefsDialog::showPrinterTab() | 1310 | void KOPrefsDialog::showPrinterTab() |
1301 | { | 1311 | { |
1302 | showPage(pageIndex(mPrinterTab)); | 1312 | showPage(pageIndex(mPrinterTab)); |
1303 | } | 1313 | } |
1304 | 1314 | ||
1305 | 1315 | ||
1306 | void KOPrefsDialog::setCombo(QComboBox *combo, const QString & text, | 1316 | void KOPrefsDialog::setCombo(QComboBox *combo, const QString & text, |
1307 | const QStringList *tags) | 1317 | const QStringList *tags) |
1308 | { | 1318 | { |
1309 | if (tags) { | 1319 | if (tags) { |
1310 | int i = tags->findIndex(text); | 1320 | int i = tags->findIndex(text); |
1311 | if (i > 0) combo->setCurrentItem(i); | 1321 | if (i > 0) combo->setCurrentItem(i); |
1312 | } else { | 1322 | } else { |
1313 | for(int i=0;i<combo->count();++i) { | 1323 | for(int i=0;i<combo->count();++i) { |
1314 | if (combo->text(i) == text) { | 1324 | if (combo->text(i) == text) { |
1315 | combo->setCurrentItem(i); | 1325 | combo->setCurrentItem(i); |
1316 | break; | 1326 | break; |
1317 | } | 1327 | } |
1318 | } | 1328 | } |
1319 | } | 1329 | } |
1320 | } | 1330 | } |
1321 | 1331 | ||
1322 | void KOPrefsDialog::usrReadConfig() | 1332 | void KOPrefsDialog::usrReadConfig() |
1323 | { | 1333 | { |
1334 | kdelibcfg->readConfig(); | ||
1324 | mNameEdit->setText(KOPrefs::instance()->fullName()); | 1335 | mNameEdit->setText(KOPrefs::instance()->fullName()); |
1325 | mEmailEdit->setText(KOPrefs::instance()->email()); | 1336 | mEmailEdit->setText(KOPrefs::instance()->email()); |
1326 | 1337 | ||
1327 | mAutoSaveIntervalSpin->setValue(KOPrefs::instance()->mAutoSaveInterval); | 1338 | mAutoSaveIntervalSpin->setValue(KOPrefs::instance()->mAutoSaveInterval); |
1328 | QDate current ( 2001, 1,1); | 1339 | QDate current ( 2001, 1,1); |
1329 | mStartDateSavingEdit->setDate(current.addDays(KOPrefs::instance()->mDaylightsavingStart-1)); | 1340 | mStartDateSavingEdit->setDate(current.addDays(KOPrefs::instance()->mDaylightsavingStart-1)); |
1330 | mEndDateSavingEdit->setDate(current.addDays(KOPrefs::instance()->mDaylightsavingEnd-1)); | 1341 | mEndDateSavingEdit->setDate(current.addDays(KOPrefs::instance()->mDaylightsavingEnd-1)); |
1331 | setCombo(mTimeZoneCombo,i18n(KOPrefs::instance()->mTimeZoneId)); | 1342 | setCombo(mTimeZoneCombo,i18n(KOPrefs::instance()->mTimeZoneId)); |
1332 | //mTimezoneOffsetSpin->setValue( KOPrefs::instance()->mTimeZoneOffset); | 1343 | //mTimezoneOffsetSpin->setValue( KOPrefs::instance()->mTimeZoneOffset); |
1333 | mStartTimeSpin->setValue(KOPrefs::instance()->mStartTime); | 1344 | mStartTimeSpin->setValue(KOPrefs::instance()->mStartTime); |
1334 | mDefaultDurationSpin->setValue(KOPrefs::instance()->mDefaultDuration); | 1345 | mDefaultDurationSpin->setValue(KOPrefs::instance()->mDefaultDuration); |
1335 | mAlarmTimeCombo->setCurrentItem(KOPrefs::instance()->mAlarmTime); | 1346 | mAlarmTimeCombo->setCurrentItem(KOPrefs::instance()->mAlarmTime); |
1336 | // if (KOPrefs::instance()->mAllDaySize > 47 ) | 1347 | // if (KOPrefs::instance()->mAllDaySize > 47 ) |
1337 | // KOPrefs::instance()->mAllDaySize = KOPrefs::instance()->mAllDaySize/2; | 1348 | // KOPrefs::instance()->mAllDaySize = KOPrefs::instance()->mAllDaySize/2; |
1338 | //mHourSizeSlider->setValue(KOPrefs::instance()->mAllDaySize); | 1349 | //mHourSizeSlider->setValue(KOPrefs::instance()->mAllDaySize); |
1339 | 1350 | ||
1340 | mNextXDaysSpin->setValue(KOPrefs::instance()->mNextXDays); | 1351 | mNextXDaysSpin->setValue(KOPrefs::instance()->mNextXDays); |
1341 | mWhatsNextSpin->setValue(KOPrefs::instance()->mWhatsNextDays); | 1352 | mWhatsNextSpin->setValue(KOPrefs::instance()->mWhatsNextDays); |
1342 | mPrioSpin->setValue(KOPrefs::instance()->mWhatsNextPrios); | 1353 | mPrioSpin->setValue(KOPrefs::instance()->mWhatsNextPrios); |
1343 | // mAMails->clear(); | 1354 | // mAMails->clear(); |
1344 | // for ( QStringList::Iterator it = KOPrefs::instance()->mAdditionalMails.begin(); | 1355 | // for ( QStringList::Iterator it = KOPrefs::instance()->mAdditionalMails.begin(); |
1345 | // it != KOPrefs::instance()->mAdditionalMails.end(); ++it ) { | 1356 | // it != KOPrefs::instance()->mAdditionalMails.end(); ++it ) { |
1346 | // QListViewItem *item = new QListViewItem(mAMails); | 1357 | // QListViewItem *item = new QListViewItem(mAMails); |
1347 | // item->setText(0,*it); | 1358 | // item->setText(0,*it); |
@@ -1349,48 +1360,49 @@ void KOPrefsDialog::usrReadConfig() | |||
1349 | // } | 1360 | // } |
1350 | 1361 | ||
1351 | // mRemoteIPEdit->setText(KOPrefs::instance()->mRemoteIP); | 1362 | // mRemoteIPEdit->setText(KOPrefs::instance()->mRemoteIP); |
1352 | //mRemoteUser->setText(KOPrefs::instance()->mRemoteUser); | 1363 | //mRemoteUser->setText(KOPrefs::instance()->mRemoteUser); |
1353 | //mRemotePassWd->setText(KOPrefs::instance()->mRemotePassWd); | 1364 | //mRemotePassWd->setText(KOPrefs::instance()->mRemotePassWd); |
1354 | //mRemoteFile->setText(KOPrefs::instance()->mRemoteFile); | 1365 | //mRemoteFile->setText(KOPrefs::instance()->mRemoteFile); |
1355 | 1366 | ||
1356 | //that soundmLocalTempFile->setText(KOPrefs::instance()->mLocalTempFile); | 1367 | //that soundmLocalTempFile->setText(KOPrefs::instance()->mLocalTempFile); |
1357 | mDefaultAlarmFile->setText(KOPrefs::instance()->mDefaultAlarmFile); | 1368 | mDefaultAlarmFile->setText(KOPrefs::instance()->mDefaultAlarmFile); |
1358 | QString dummy = KOPrefs::instance()->mUserDateFormatLong; | 1369 | QString dummy = KOPrefs::instance()->mUserDateFormatLong; |
1359 | mUserDateFormatLong->setText(dummy.replace( QRegExp("K"), QString(",") )); | 1370 | mUserDateFormatLong->setText(dummy.replace( QRegExp("K"), QString(",") )); |
1360 | dummy = KOPrefs::instance()->mUserDateFormatShort; | 1371 | dummy = KOPrefs::instance()->mUserDateFormatShort; |
1361 | mUserDateFormatShort->setText(dummy.replace( QRegExp("K"), QString(",") )); | 1372 | mUserDateFormatShort->setText(dummy.replace( QRegExp("K"), QString(",") )); |
1362 | updateCategories(); | 1373 | updateCategories(); |
1363 | mAlarmPlayBeeps->setValue(KOPrefs::instance()->mAlarmPlayBeeps ); | 1374 | mAlarmPlayBeeps->setValue(KOPrefs::instance()->mAlarmPlayBeeps ); |
1364 | mAlarmSuspendTime->setValue(KOPrefs::instance()->mAlarmSuspendTime ); | 1375 | mAlarmSuspendTime->setValue(KOPrefs::instance()->mAlarmSuspendTime ); |
1365 | mAlarmSuspendCount->setValue(KOPrefs::instance()->mAlarmSuspendCount ); | 1376 | mAlarmSuspendCount->setValue(KOPrefs::instance()->mAlarmSuspendCount ); |
1366 | mAlarmBeepInterval->setValue(KOPrefs::instance()->mAlarmBeepInterval ); | 1377 | mAlarmBeepInterval->setValue(KOPrefs::instance()->mAlarmBeepInterval ); |
1367 | } | 1378 | } |
1368 | 1379 | ||
1369 | 1380 | ||
1370 | void KOPrefsDialog::usrWriteConfig() | 1381 | void KOPrefsDialog::usrWriteConfig() |
1371 | { | 1382 | { |
1372 | 1383 | ||
1384 | kdelibcfg->writeConfig(); | ||
1373 | // KOPrefs::instance()->mRemoteIP = mRemoteIPEdit->text(); | 1385 | // KOPrefs::instance()->mRemoteIP = mRemoteIPEdit->text(); |
1374 | //KOPrefs::instance()->mRemoteUser = mRemoteUser->text(); | 1386 | //KOPrefs::instance()->mRemoteUser = mRemoteUser->text(); |
1375 | //KOPrefs::instance()->mRemotePassWd = mRemotePassWd->text(); | 1387 | //KOPrefs::instance()->mRemotePassWd = mRemotePassWd->text(); |
1376 | //KOPrefs::instance()->mRemoteFile= mRemoteFile->text(); | 1388 | //KOPrefs::instance()->mRemoteFile= mRemoteFile->text(); |
1377 | //KOPrefs::instance()->mLocalTempFile =mLocalTempFile->text(); | 1389 | //KOPrefs::instance()->mLocalTempFile =mLocalTempFile->text(); |
1378 | KOPrefs::instance()->mDefaultAlarmFile =mDefaultAlarmFile->text(); | 1390 | KOPrefs::instance()->mDefaultAlarmFile =mDefaultAlarmFile->text(); |
1379 | 1391 | ||
1380 | KOPrefs::instance()->mUserDateFormatShort = mUserDateFormatShort->text().replace( QRegExp(","), QString("K") ); | 1392 | KOPrefs::instance()->mUserDateFormatShort = mUserDateFormatShort->text().replace( QRegExp(","), QString("K") ); |
1381 | KOPrefs::instance()->mUserDateFormatLong = mUserDateFormatLong->text().replace( QRegExp(","), QString("K") ); | 1393 | KOPrefs::instance()->mUserDateFormatLong = mUserDateFormatLong->text().replace( QRegExp(","), QString("K") ); |
1382 | KOPrefs::instance()->setFullName(mNameEdit->text()); | 1394 | KOPrefs::instance()->setFullName(mNameEdit->text()); |
1383 | KOPrefs::instance()->setEmail(mEmailEdit->text()); | 1395 | KOPrefs::instance()->setEmail(mEmailEdit->text()); |
1384 | 1396 | ||
1385 | KOPrefs::instance()->mAutoSaveInterval = mAutoSaveIntervalSpin->value(); | 1397 | KOPrefs::instance()->mAutoSaveInterval = mAutoSaveIntervalSpin->value(); |
1386 | 1398 | ||
1387 | KOPrefs::instance()->mTimeZoneId = mTimeZoneCombo->currentText(); | 1399 | KOPrefs::instance()->mTimeZoneId = mTimeZoneCombo->currentText(); |
1388 | QDate date; | 1400 | QDate date; |
1389 | date = mStartDateSavingEdit->date(); | 1401 | date = mStartDateSavingEdit->date(); |
1390 | int sub = 0; | 1402 | int sub = 0; |
1391 | if ( QDate::leapYear( date.year() ) && date.dayOfYear() > 59 ) | 1403 | if ( QDate::leapYear( date.year() ) && date.dayOfYear() > 59 ) |
1392 | sub = 1; | 1404 | sub = 1; |
1393 | KOPrefs::instance()->mDaylightsavingStart = date.dayOfYear()-sub; | 1405 | KOPrefs::instance()->mDaylightsavingStart = date.dayOfYear()-sub; |
1394 | date = mEndDateSavingEdit->date(); | 1406 | date = mEndDateSavingEdit->date(); |
1395 | if ( QDate::leapYear( date.year() ) && date.dayOfYear() > 59 ) | 1407 | if ( QDate::leapYear( date.year() ) && date.dayOfYear() > 59 ) |
1396 | sub = 1; | 1408 | sub = 1; |
diff --git a/korganizer/koprefsdialog.h b/korganizer/koprefsdialog.h index 83dc1eb..e20969a 100644 --- a/korganizer/koprefsdialog.h +++ b/korganizer/koprefsdialog.h | |||
@@ -11,115 +11,118 @@ | |||
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of | 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
13 | GNU General Public License for more details. | 13 | GNU General Public License for more details. |
14 | 14 | ||
15 | You should have received a copy of the GNU General Public License | 15 | You should have received a copy of the GNU General Public License |
16 | along with this program; if not, write to the Free Software | 16 | along with this program; if not, write to the Free Software |
17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | 17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
18 | 18 | ||
19 | As a special exception, permission is given to link this program | 19 | As a special exception, permission is given to link this program |
20 | with any edition of Qt, and distribute the resulting executable, | 20 | with any edition of Qt, and distribute the resulting executable, |
21 | without including the source code for Qt in the source distribution. | 21 | without including the source code for Qt in the source distribution. |
22 | */ | 22 | */ |
23 | #ifndef _KOPREFSDIALOG_H | 23 | #ifndef _KOPREFSDIALOG_H |
24 | #define _KOPREFSDIALOG_H | 24 | #define _KOPREFSDIALOG_H |
25 | 25 | ||
26 | #include <qframe.h> | 26 | #include <qframe.h> |
27 | #include <qdict.h> | 27 | #include <qdict.h> |
28 | #include <qcolor.h> | 28 | #include <qcolor.h> |
29 | #include <qlistview.h> | 29 | #include <qlistview.h> |
30 | 30 | ||
31 | #include <kdialogbase.h> | 31 | #include <kdialogbase.h> |
32 | 32 | ||
33 | #include <libkdepim/kprefsdialog.h> | 33 | #include <libkdepim/kprefsdialog.h> |
34 | #include <libkdepim/kdateedit.h> | 34 | #include <libkdepim/kdateedit.h> |
35 | #include <kcmconfigs/kdepimconfigwidget.h> | ||
35 | 36 | ||
36 | class KColorButton; | 37 | class KColorButton; |
37 | class QSpinBox; | 38 | class QSpinBox; |
38 | class QSlider; | 39 | class QSlider; |
39 | class KURLRequester; | 40 | class KURLRequester; |
40 | class QComboBox; | 41 | class QComboBox; |
41 | class QLineEdit; | 42 | class QLineEdit; |
42 | class QStringList; | 43 | class QStringList; |
43 | 44 | ||
44 | /** Dialog to change the korganizer configuration. | 45 | /** Dialog to change the korganizer configuration. |
45 | */ | 46 | */ |
46 | class KOPrefsDialog : public KPrefsDialog | 47 | class KOPrefsDialog : public KPrefsDialog |
47 | { | 48 | { |
48 | Q_OBJECT | 49 | Q_OBJECT |
49 | public: | 50 | public: |
50 | /** Initialize dialog and pages */ | 51 | /** Initialize dialog and pages */ |
51 | KOPrefsDialog(QWidget *parent=0,char *name=0,bool modal=false); | 52 | KOPrefsDialog(QWidget *parent=0,char *name=0,bool modal=false); |
52 | ~KOPrefsDialog(); | 53 | ~KOPrefsDialog(); |
53 | 54 | ||
54 | public slots: | 55 | public slots: |
55 | void showPrinterTab(); | 56 | void showPrinterTab(); |
56 | 57 | ||
57 | /** Update controls for categories */ | 58 | /** Update controls for categories */ |
58 | void updateCategories(); | 59 | void updateCategories(); |
59 | void showSyncPage(); | 60 | void showSyncPage(); |
60 | protected slots: | 61 | protected slots: |
61 | void selectSoundFile(); | 62 | void selectSoundFile(); |
62 | void setCategoryColor(); | 63 | void setCategoryColor(); |
63 | void updateCategoryColor(); | 64 | void updateCategoryColor(); |
64 | void updateTimezoneOffset( int ); | 65 | void updateTimezoneOffset( int ); |
65 | 66 | ||
66 | 67 | ||
67 | void warningExperimental(bool on); | 68 | void warningExperimental(bool on); |
68 | void warningGroupScheduling(); | 69 | void warningGroupScheduling(); |
69 | void warningProjectView(); | 70 | void warningProjectView(); |
70 | 71 | ||
71 | void toggleEmailSettings(bool); | 72 | void toggleEmailSettings(bool); |
72 | 73 | ||
73 | //additional emails | 74 | //additional emails |
74 | void addItem(); | 75 | void addItem(); |
75 | void removeItem(); | 76 | void removeItem(); |
76 | void updateItem(); | 77 | void updateItem(); |
77 | void updateInput(); | 78 | void updateInput(); |
78 | 79 | ||
79 | protected: | 80 | protected: |
80 | void usrReadConfig(); | 81 | void usrReadConfig(); |
81 | void usrWriteConfig(); | 82 | void usrWriteConfig(); |
83 | void setupGlobalTab(); | ||
82 | 84 | ||
83 | void setupMainTab(); | 85 | void setupMainTab(); |
84 | void setupTimeTab(); | 86 | void setupTimeTab(); |
85 | void setupTimeZoneTab(); | 87 | void setupTimeZoneTab(); |
86 | void setupLocaleTab(); | 88 | void setupLocaleTab(); |
87 | void setupLocaleDateTab(); | 89 | void setupLocaleDateTab(); |
88 | void setupFontsTab(); | 90 | void setupFontsTab(); |
89 | void setupColorsTab(); | 91 | void setupColorsTab(); |
90 | void setupViewsTab(); | 92 | void setupViewsTab(); |
91 | void setupDisplayTab(); | 93 | void setupDisplayTab(); |
92 | void setupPrinterTab(); | 94 | void setupPrinterTab(); |
93 | void setupGroupSchedulingTab(); | 95 | void setupGroupSchedulingTab(); |
94 | void setupGroupAutomationTab(); | 96 | void setupGroupAutomationTab(); |
95 | void setupSyncTab(); | 97 | void setupSyncTab(); |
96 | void setupSyncAlgTab(); | 98 | void setupSyncAlgTab(); |
97 | 99 | ||
98 | void setCombo(QComboBox *combo,const QString & text, const QStringList *tags = 0); | 100 | void setCombo(QComboBox *combo,const QString & text, const QStringList *tags = 0); |
99 | 101 | ||
100 | 102 | ||
101 | private: | 103 | private: |
104 | KDEPIMConfigWidget* kdelibcfg; | ||
102 | KPrefsDialogWidBool *mEnableGroupScheduling; | 105 | KPrefsDialogWidBool *mEnableGroupScheduling; |
103 | KPrefsDialogWidBool *mEnableProjectView; | 106 | KPrefsDialogWidBool *mEnableProjectView; |
104 | 107 | ||
105 | QFrame *mPrinterTab; | 108 | QFrame *mPrinterTab; |
106 | 109 | ||
107 | QLineEdit *nameEdit; | 110 | QLineEdit *nameEdit; |
108 | QLineEdit *emailEdit; | 111 | QLineEdit *emailEdit; |
109 | 112 | ||
110 | QComboBox *timeCombo; | 113 | QComboBox *timeCombo; |
111 | QComboBox *tzCombo; | 114 | QComboBox *tzCombo; |
112 | 115 | ||
113 | // widgets holding preferences data | 116 | // widgets holding preferences data |
114 | QLineEdit *mNameEdit; | 117 | QLineEdit *mNameEdit; |
115 | QLineEdit *mEmailEdit; | 118 | QLineEdit *mEmailEdit; |
116 | QLabel *mNameLabel; | 119 | QLabel *mNameLabel; |
117 | QLabel *mEmailLabel; | 120 | QLabel *mEmailLabel; |
118 | QLineEdit *mAdditionalEdit; | 121 | QLineEdit *mAdditionalEdit; |
119 | QSpinBox *mAutoSaveIntervalSpin; | 122 | QSpinBox *mAutoSaveIntervalSpin; |
120 | QSpinBox *mPrioSpin; | 123 | QSpinBox *mPrioSpin; |
121 | // QListView *mAMails; | 124 | // QListView *mAMails; |
122 | QLineEdit *aEmailsEdit; | 125 | QLineEdit *aEmailsEdit; |
123 | 126 | ||
124 | QComboBox *mTimeZoneCombo; | 127 | QComboBox *mTimeZoneCombo; |
125 | QStringList tzonenames; | 128 | QStringList tzonenames; |