summaryrefslogtreecommitdiff
path: root/src/displayapp
diff options
context:
space:
mode:
authorJF002 <JF002@users.noreply.github.com>2021-09-23 20:13:42 +0200
committerGitHub <noreply@github.com>2021-09-23 20:13:42 +0200
commit8a2b86dc8376d915b664a301465f7a5ef675b66f (patch)
treee9e5efad34e3ab0ed7e3651364ab09985b5c9bcb /src/displayapp
parent1c3c3c8db919c703bbd3f1be4ce9c6833237ea6f (diff)
parent93d240a23b1071efd0ac4ecba986f98bc1dae2a4 (diff)
Merge pull request #664 from Riksu9000/disable_notif_only
Toggle notifications only, keep vibrations.
Diffstat (limited to 'src/displayapp')
-rw-r--r--src/displayapp/screens/Notifications.cpp4
-rw-r--r--src/displayapp/screens/settings/QuickSettings.cpp6
2 files changed, 3 insertions, 7 deletions
diff --git a/src/displayapp/screens/Notifications.cpp b/src/displayapp/screens/Notifications.cpp
index 417dff00..4f475813 100644
--- a/src/displayapp/screens/Notifications.cpp
+++ b/src/displayapp/screens/Notifications.cpp
@@ -129,10 +129,6 @@ bool Notifications::OnTouchEvent(Pinetime::Applications::TouchEvents event) {
alertNotificationService);
}
return true;
- case Pinetime::Applications::TouchEvents::LongTap: {
- // notificationManager.ToggleVibrations();
- return true;
- }
default:
return false;
}
diff --git a/src/displayapp/screens/settings/QuickSettings.cpp b/src/displayapp/screens/settings/QuickSettings.cpp
index 22b56360..691c40c8 100644
--- a/src/displayapp/screens/settings/QuickSettings.cpp
+++ b/src/displayapp/screens/settings/QuickSettings.cpp
@@ -88,7 +88,7 @@ QuickSettings::QuickSettings(Pinetime::Applications::DisplayApp* app,
btn3_lvl = lv_label_create(btn3, nullptr);
lv_obj_set_style_local_text_font(btn3_lvl, LV_LABEL_PART_MAIN, LV_STATE_DEFAULT, &lv_font_sys_48);
- if (settingsController.GetVibrationStatus() == Controllers::Settings::Vibration::ON) {
+ if (settingsController.GetNotificationStatus() == Controllers::Settings::Notification::ON) {
lv_obj_add_state(btn3, LV_STATE_CHECKED);
lv_label_set_text_static(btn3_lvl, Symbols::notificationsOn);
} else {
@@ -142,11 +142,11 @@ void QuickSettings::OnButtonEvent(lv_obj_t* object, lv_event_t event) {
} else if (object == btn3 && event == LV_EVENT_VALUE_CHANGED) {
if (lv_obj_get_state(btn3, LV_BTN_PART_MAIN) & LV_STATE_CHECKED) {
- settingsController.SetVibrationStatus(Controllers::Settings::Vibration::ON);
+ settingsController.SetNotificationStatus(Controllers::Settings::Notification::ON);
motorController.RunForDuration(35);
lv_label_set_text_static(btn3_lvl, Symbols::notificationsOn);
} else {
- settingsController.SetVibrationStatus(Controllers::Settings::Vibration::OFF);
+ settingsController.SetNotificationStatus(Controllers::Settings::Notification::OFF);
lv_label_set_text_static(btn3_lvl, Symbols::notificationsOff);
}