author | zautrix <zautrix> | 2005-06-29 14:28:51 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2005-06-29 14:28:51 (UTC) |
commit | e0fa858c284dddf0d47146e666c4ece7158487be (patch) (unidiff) | |
tree | 65ffa534d76019376095d4ffa1a36faee4e25880 | |
parent | f29d4de96b6fd334ff64f11731f5d4899b69f124 (diff) | |
download | kdepimpi-e0fa858c284dddf0d47146e666c4ece7158487be.zip kdepimpi-e0fa858c284dddf0d47146e666c4ece7158487be.tar.gz kdepimpi-e0fa858c284dddf0d47146e666c4ece7158487be.tar.bz2 |
fixxx
-rw-r--r-- | korganizer/koprefsdialog.cpp | 14 | ||||
-rw-r--r-- | korganizer/koprefsdialog.h | 1 |
2 files changed, 11 insertions, 4 deletions
diff --git a/korganizer/koprefsdialog.cpp b/korganizer/koprefsdialog.cpp index 7ba1392..ebcff33 100644 --- a/korganizer/koprefsdialog.cpp +++ b/korganizer/koprefsdialog.cpp | |||
@@ -1413,49 +1413,55 @@ void KOPrefsDialog::usrReadConfig() | |||
1413 | mPrioSpin->setValue(KOPrefs::instance()->mWhatsNextPrios); | 1413 | mPrioSpin->setValue(KOPrefs::instance()->mWhatsNextPrios); |
1414 | // mAMails->clear(); | 1414 | // mAMails->clear(); |
1415 | // for ( QStringList::Iterator it = KOPrefs::instance()->mAdditionalMails.begin(); | 1415 | // for ( QStringList::Iterator it = KOPrefs::instance()->mAdditionalMails.begin(); |
1416 | // it != KOPrefs::instance()->mAdditionalMails.end(); ++it ) { | 1416 | // it != KOPrefs::instance()->mAdditionalMails.end(); ++it ) { |
1417 | // QListViewItem *item = new QListViewItem(mAMails); | 1417 | // QListViewItem *item = new QListViewItem(mAMails); |
1418 | // item->setText(0,*it); | 1418 | // item->setText(0,*it); |
1419 | // mAMails->insertItem(item); | 1419 | // mAMails->insertItem(item); |
1420 | // } | 1420 | // } |
1421 | 1421 | ||
1422 | //that soundmLocalTempFile->setText(KOPrefs::instance()->mLocalTempFile); | 1422 | //that soundmLocalTempFile->setText(KOPrefs::instance()->mLocalTempFile); |
1423 | mDefaultAlarmFile->setText(KOPrefs::instance()->mDefaultAlarmFile); | 1423 | mDefaultAlarmFile->setText(KOPrefs::instance()->mDefaultAlarmFile); |
1424 | updateCategories(); | 1424 | updateCategories(); |
1425 | mAlarmPlayBeeps->setValue(KOPrefs::instance()->mAlarmPlayBeeps ); | 1425 | mAlarmPlayBeeps->setValue(KOPrefs::instance()->mAlarmPlayBeeps ); |
1426 | mAlarmSuspendTime->setValue(KOPrefs::instance()->mAlarmSuspendTime ); | 1426 | mAlarmSuspendTime->setValue(KOPrefs::instance()->mAlarmSuspendTime ); |
1427 | mAlarmSuspendCount->setValue(KOPrefs::instance()->mAlarmSuspendCount ); | 1427 | mAlarmSuspendCount->setValue(KOPrefs::instance()->mAlarmSuspendCount ); |
1428 | mAlarmBeepInterval->setValue(KOPrefs::instance()->mAlarmBeepInterval ); | 1428 | mAlarmBeepInterval->setValue(KOPrefs::instance()->mAlarmBeepInterval ); |
1429 | 1429 | mCatDefaultColor = KOPrefs::instance()->mEventColor; | |
1430 | } | 1430 | } |
1431 | 1431 | ||
1432 | 1432 | ||
1433 | void KOPrefsDialog::usrWriteConfig() | 1433 | void KOPrefsDialog::usrWriteConfig() |
1434 | { | 1434 | { |
1435 | |||
1436 | |||
1437 | KOPrefs::instance()->mDefaultAlarmFile =mDefaultAlarmFile->text(); | 1435 | KOPrefs::instance()->mDefaultAlarmFile =mDefaultAlarmFile->text(); |
1438 | KOPrefs::instance()->setFullName(mNameEdit->text()); | 1436 | KOPrefs::instance()->setFullName(mNameEdit->text()); |
1439 | KOPrefs::instance()->setEmail(mEmailEdit->text()); | 1437 | KOPrefs::instance()->setEmail(mEmailEdit->text()); |
1440 | 1438 | ||
1441 | KOPrefs::instance()->mAutoSaveInterval = mAutoSaveIntervalSpin->value(); | 1439 | KOPrefs::instance()->mAutoSaveInterval = mAutoSaveIntervalSpin->value(); |
1442 | KOPrefs::instance()->mStartTime = mStartTimeSpin->value(); | 1440 | KOPrefs::instance()->mStartTime = mStartTimeSpin->value(); |
1443 | KOPrefs::instance()->mDefaultDuration = mDefaultDurationSpin->value(); | 1441 | KOPrefs::instance()->mDefaultDuration = mDefaultDurationSpin->value(); |
1444 | KOPrefs::instance()->mAlarmTime = mAlarmTimeCombo->currentItem(); | 1442 | KOPrefs::instance()->mAlarmTime = mAlarmTimeCombo->currentItem(); |
1445 | 1443 | if ( mCatDefaultColor != KOPrefs::instance()->mEventColor ) { | |
1444 | QStringList cat = KOPrefs::instance()->mCustomCategories; | ||
1445 | int iii = 0; | ||
1446 | while ( iii < cat.count() ) { | ||
1447 | if ( *KOPrefs::instance()->categoryColor( cat[ iii ] ) == mCatDefaultColor ) | ||
1448 | KOPrefs::instance()->setCategoryColor( cat[ iii ], KOPrefs::instance()->mEventColor ); | ||
1449 | ++iii; | ||
1450 | } | ||
1451 | } | ||
1446 | QDictIterator<QColor> it(mCategoryDict); | 1452 | QDictIterator<QColor> it(mCategoryDict); |
1447 | while (it.current()) { | 1453 | while (it.current()) { |
1448 | KOPrefs::instance()->setCategoryColor(it.currentKey(),*it.current()); | 1454 | KOPrefs::instance()->setCategoryColor(it.currentKey(),*it.current()); |
1449 | ++it; | 1455 | ++it; |
1450 | } | 1456 | } |
1451 | 1457 | ||
1452 | KOPrefs::instance()->mNextXDays = mNextXDaysSpin->value(); | 1458 | KOPrefs::instance()->mNextXDays = mNextXDaysSpin->value(); |
1453 | KOPrefs::instance()->mWhatsNextDays = mWhatsNextSpin->value(); | 1459 | KOPrefs::instance()->mWhatsNextDays = mWhatsNextSpin->value(); |
1454 | KOPrefs::instance()->mWhatsNextPrios = mPrioSpin->value(); | 1460 | KOPrefs::instance()->mWhatsNextPrios = mPrioSpin->value(); |
1455 | 1461 | ||
1456 | KOPrefs::instance()->mAdditionalMails.clear(); | 1462 | KOPrefs::instance()->mAdditionalMails.clear(); |
1457 | // QListViewItem *item; | 1463 | // QListViewItem *item; |
1458 | // item = mAMails->firstChild(); | 1464 | // item = mAMails->firstChild(); |
1459 | // while (item) | 1465 | // while (item) |
1460 | // { | 1466 | // { |
1461 | // KOPrefs::instance()->mAdditionalMails.append( item->text(0) ); | 1467 | // KOPrefs::instance()->mAdditionalMails.append( item->text(0) ); |
diff --git a/korganizer/koprefsdialog.h b/korganizer/koprefsdialog.h index 80d6545..baa6cf9 100644 --- a/korganizer/koprefsdialog.h +++ b/korganizer/koprefsdialog.h | |||
@@ -77,32 +77,33 @@ class KOPrefsDialog : public KPrefsDialog | |||
77 | void setupMainTab(); | 77 | void setupMainTab(); |
78 | void setupTimeTab(); | 78 | void setupTimeTab(); |
79 | void setupLocaleTab(); | 79 | void setupLocaleTab(); |
80 | void setupLocaleDateTab(); | 80 | void setupLocaleDateTab(); |
81 | void setupFontsTab(); | 81 | void setupFontsTab(); |
82 | void setupColorsTab(); | 82 | void setupColorsTab(); |
83 | void setupViewsTab(); | 83 | void setupViewsTab(); |
84 | void setupDisplayTab(); | 84 | void setupDisplayTab(); |
85 | void setupPrinterTab(); | 85 | void setupPrinterTab(); |
86 | void setupGroupSchedulingTab(); | 86 | void setupGroupSchedulingTab(); |
87 | void setupGroupAutomationTab(); | 87 | void setupGroupAutomationTab(); |
88 | 88 | ||
89 | void setCombo(QComboBox *combo,const QString & text, const QStringList *tags = 0); | 89 | void setCombo(QComboBox *combo,const QString & text, const QStringList *tags = 0); |
90 | 90 | ||
91 | 91 | ||
92 | private: | 92 | private: |
93 | QColor mCatDefaultColor; | ||
93 | KPrefsDialogWidBool *mEnableGroupScheduling; | 94 | KPrefsDialogWidBool *mEnableGroupScheduling; |
94 | KPrefsDialogWidBool *mEnableProjectView; | 95 | KPrefsDialogWidBool *mEnableProjectView; |
95 | 96 | ||
96 | QFrame *mPrinterTab; | 97 | QFrame *mPrinterTab; |
97 | 98 | ||
98 | QLineEdit *nameEdit; | 99 | QLineEdit *nameEdit; |
99 | QLineEdit *emailEdit; | 100 | QLineEdit *emailEdit; |
100 | 101 | ||
101 | QComboBox *timeCombo; | 102 | QComboBox *timeCombo; |
102 | QComboBox *tzCombo; | 103 | QComboBox *tzCombo; |
103 | 104 | ||
104 | // widgets holding preferences data | 105 | // widgets holding preferences data |
105 | QLineEdit *mNameEdit; | 106 | QLineEdit *mNameEdit; |
106 | QLineEdit *mEmailEdit; | 107 | QLineEdit *mEmailEdit; |
107 | QLabel *mNameLabel; | 108 | QLabel *mNameLabel; |
108 | QLabel *mEmailLabel; | 109 | QLabel *mEmailLabel; |