|
@ -130,10 +130,15 @@ double MainWindow::get_target_temperature(int room_idx) |
|
|
goto out; |
|
|
goto out; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/*
|
|
|
|
|
|
* dayOfWeek() returns 1 for monday, 7 for sunday. |
|
|
|
|
|
* so dow <<= 1 gives 0 for monday, 6 for sunday. |
|
|
|
|
|
* And (1 << dow) gives the day of week as a bit field |
|
|
|
|
|
*/ |
|
|
dow <<= 1; |
|
|
dow <<= 1; |
|
|
for (int i = 0; i < r->progs.count(); i++) { |
|
|
for (int i = 0; i < r->progs.count(); i++) { |
|
|
p = &(r->progs.at(i)); |
|
|
p = &(r->progs.at(i)); |
|
|
if (dow & p->DoW) { |
|
|
|
|
|
|
|
|
if ((1 << dow) & p->DoW) { |
|
|
if (p->start_time == p->end_time) { |
|
|
if (p->start_time == p->end_time) { |
|
|
continue; |
|
|
continue; |
|
|
} |
|
|
} |
|
|