format changes
This commit is contained in:
parent
37de10f47d
commit
822b6ae6a0
|
@ -75,19 +75,21 @@ void DateTime::UpdateTime(uint32_t systickCounter) {
|
|||
minute = time.minutes().count();
|
||||
second = time.seconds().count();
|
||||
|
||||
if (minute == 0 and not isHourAlreadyNotified) {
|
||||
if (minute == 0 && !isHourAlreadyNotified) {
|
||||
isHourAlreadyNotified = true;
|
||||
if (systemTask != nullptr)
|
||||
if (systemTask != nullptr) {
|
||||
systemTask->PushMessage(System::Messages::OnNewHour);
|
||||
}
|
||||
} else if (minute != 0) {
|
||||
isHourAlreadyNotified = false;
|
||||
}
|
||||
|
||||
if ((minute == 0 or minute == 30) and not isHalfHourAlreadyNotified) {
|
||||
if ((minute == 0 || minute == 30) && !isHalfHourAlreadyNotified) {
|
||||
isHalfHourAlreadyNotified = true;
|
||||
if (systemTask != nullptr)
|
||||
if (systemTask != nullptr) {
|
||||
systemTask->PushMessage(System::Messages::OnNewHalfHour);
|
||||
} else if (minute != 0 and minute != 30) {
|
||||
}
|
||||
} else if (minute != 0 && minute != 30) {
|
||||
isHalfHourAlreadyNotified = false;
|
||||
}
|
||||
|
||||
|
|
|
@ -354,7 +354,7 @@ void SystemTask::Work() {
|
|||
break;
|
||||
case Messages::OnNewHour:
|
||||
using Pinetime::Controllers::AlarmController;
|
||||
if (settingsController.GetChimesState() == 1 and alarmController.State() != AlarmController::AlarmState::Alerting) {
|
||||
if (settingsController.GetChimesState() == 1 && alarmController.State() != AlarmController::AlarmState::Alerting) {
|
||||
if (isSleeping && !isWakingUp) {
|
||||
GoToRunning();
|
||||
displayApp.PushMessage(Pinetime::Applications::Display::Messages::Clock);
|
||||
|
@ -364,7 +364,7 @@ void SystemTask::Work() {
|
|||
break;
|
||||
case Messages::OnNewHalfHour:
|
||||
using Pinetime::Controllers::AlarmController;
|
||||
if (settingsController.GetChimesState() == 2 and alarmController.State() != AlarmController::AlarmState::Alerting) {
|
||||
if (settingsController.GetChimesState() == 2 && alarmController.State() != AlarmController::AlarmState::Alerting) {
|
||||
if (isSleeping && !isWakingUp) {
|
||||
GoToRunning();
|
||||
displayApp.PushMessage(Pinetime::Applications::Display::Messages::Clock);
|
||||
|
|
Loading…
Reference in New Issue