summaryrefslogtreecommitdiffstats
path: root/korganizer/koprefsdialog.cpp
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-05-14 02:06:47 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-05-14 02:06:47 +0000
commitacc2b77512ce0d8d708dda14dec1464f3eed830c (patch)
tree7917cc141e67ba40a4d4b06c752b66ede069b3da /korganizer/koprefsdialog.cpp
parent54887c51b14c7707178d43d39413bf1bc7a17472 (diff)
downloadtdepim-acc2b77512ce0d8d708dda14dec1464f3eed830c.tar.gz
tdepim-acc2b77512ce0d8d708dda14dec1464f3eed830c.zip
Second batch of kdepim stability and functionality repairs
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdepim@1126473 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'korganizer/koprefsdialog.cpp')
-rw-r--r--korganizer/koprefsdialog.cpp13
1 files changed, 11 insertions, 2 deletions
diff --git a/korganizer/koprefsdialog.cpp b/korganizer/koprefsdialog.cpp
index 99045c309..fd9fd8246 100644
--- a/korganizer/koprefsdialog.cpp
+++ b/korganizer/koprefsdialog.cpp
@@ -331,11 +331,17 @@ class KOPrefsDialogTime : public KPrefsModule
mAlarmTimeCombo->insertStringList( alarmList );
topLayout->addWidget( mAlarmTimeCombo, 5, 1 );
+ QLabel *alarmDefaultLabel = new QLabel( i18n( "Enable reminders by default:" ), topFrame);
+ topLayout->addWidget( alarmDefaultLabel, 6, 0 );
+ mAlarmTimeDefaultCheckBox = new QCheckBox( topFrame );
+ topLayout->addWidget( mAlarmTimeDefaultCheckBox, 6, 1 );
+ connect( mAlarmTimeDefaultCheckBox, SIGNAL( toggled( bool ) ),
+ SLOT( slotWidChanged() ) );
QGroupBox *workingHoursGroup = new QGroupBox(1,Horizontal,
i18n("Working Hours"),
topFrame);
- topLayout->addMultiCellWidget( workingHoursGroup, 6, 6, 0, 1 );
+ topLayout->addMultiCellWidget( workingHoursGroup, 7, 7, 0, 1 );
QHBox *workDaysBox = new QHBox( workingHoursGroup );
// Respect start of week setting
@@ -369,7 +375,7 @@ class KOPrefsDialogTime : public KPrefsModule
addWidBool( KOPrefs::instance()->excludeHolidaysItem(),
workingHoursGroup );
- topLayout->setRowStretch(7,1);
+ topLayout->setRowStretch(8,1);
load();
}
@@ -381,6 +387,7 @@ class KOPrefsDialogTime : public KPrefsModule
i18n( KOPrefs::instance()->mTimeZoneId.utf8() ) );
mAlarmTimeCombo->setCurrentItem( KOPrefs::instance()->mAlarmTime );
+ mAlarmTimeDefaultCheckBox->setChecked ( KOPrefs::instance()->mAlarmsEnabledByDefault );
for ( int i = 0; i < 7; ++i ) {
mWorkDays[i]->setChecked( (1<<i) & (KOPrefs::instance()->mWorkWeekMask) );
}
@@ -403,6 +410,7 @@ class KOPrefsDialogTime : public KPrefsModule
mRegionMap[mHolidayCombo->currentText()];
KOPrefs::instance()->mAlarmTime = mAlarmTimeCombo->currentItem();
+ KOPrefs::instance()->mAlarmsEnabledByDefault = mAlarmTimeDefaultCheckBox->isChecked();
int mask = 0;
for ( int i = 0; i < 7; ++i ) {
if (mWorkDays[i]->isChecked()) mask = mask | (1<<i);
@@ -433,6 +441,7 @@ class KOPrefsDialogTime : public KPrefsModule
QComboBox *mHolidayCombo;
QMap<QString,QString> mRegionMap;
QComboBox *mAlarmTimeCombo;
+ QCheckBox *mAlarmTimeDefaultCheckBox;
QCheckBox *mWorkDays[7];
};