diff options
Diffstat (limited to 'plugins')
-rwxr-xr-x | plugins/Alarms/src/alarmlist.cpp | 13 | ||||
-rwxr-xr-x | plugins/Alarms/src/options.cpp | 3 |
2 files changed, 11 insertions, 5 deletions
diff --git a/plugins/Alarms/src/alarmlist.cpp b/plugins/Alarms/src/alarmlist.cpp index 6988f436f6..d9bb0ed360 100755 --- a/plugins/Alarms/src/alarmlist.cpp +++ b/plugins/Alarms/src/alarmlist.cpp @@ -279,6 +279,10 @@ void LoadAlarms() break;
case OC_WEEKDAYS:
break;
+ case OC_SELECTED_DAYS:
+ mir_snprintf(buff, "SelectedDays%d", i);
+ alarm.day_mask = db_get_dw(0, MODULE, buff, alarm.day_mask);
+ break;
case OC_DAILY:
break;
case OC_MONTHLY:
@@ -327,9 +331,6 @@ void LoadAlarms() mir_snprintf(buff, "Flags%d", i);
alarm.flags = db_get_dw(0, MODULE, buff, alarm.flags);
- mir_snprintf(buff, "SelectedDays%d", i);
- alarm.flags = db_get_dw(0, MODULE, buff, alarm.day_mask);
-
alarm.id = next_alarm_id++;
alarms.push_back(&alarm);
}
@@ -365,6 +366,10 @@ void SaveAlarms() break;
case OC_WEEKDAYS:
break;
+ case OC_SELECTED_DAYS:
+ mir_snprintf(buff, "SelectedDays%d", index);
+ db_set_dw(0, MODULE, buff, i->day_mask);
+ break;
case OC_WEEKLY:
mir_snprintf(buff, "STDayOfWeek%d", index);
db_set_w(0, MODULE, buff, i->time.wDayOfWeek);
@@ -402,8 +407,6 @@ void SaveAlarms() mir_snprintf(buff, "Flags%d", index);
db_set_dw(0, MODULE, buff, i->flags);
- mir_snprintf(buff, "SelectedDays%d", index);
- db_set_dw(0, MODULE, buff, i->day_mask);
}
db_set_w(0, MODULE, "Count", index);
}
diff --git a/plugins/Alarms/src/options.cpp b/plugins/Alarms/src/options.cpp index 381e38b674..dbc5cf3dcc 100755 --- a/plugins/Alarms/src/options.cpp +++ b/plugins/Alarms/src/options.cpp @@ -591,6 +591,9 @@ static INT_PTR CALLBACK DlgProcAddEdit(HWND hwndDlg, UINT msg, WPARAM wParam, LP SendMessage(hwndDlg, WMU_UPDATETIME, 0, 0);
SendMessage(hwndDlg, WMU_SETTIME, 0, 0);
break;
+ case IDC_CHK_DAY1: case IDC_CHK_DAY2: case IDC_CHK_DAY3: case IDC_CHK_DAY4: case IDC_CHK_DAY5: case IDC_CHK_DAY6: case IDC_CHK_DAY7:
+ EnableWindow(GetDlgItem(hwndDlg, IDOK), TRUE);
+ break;
case IDC_CHK_ACOMMAND:
bChecked = IsDlgButtonChecked(hwndDlg, IDC_CHK_ACOMMAND) != 0;
|