aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/snap.cpp6
-rw-r--r--tests/test-notification.cpp6
2 files changed, 9 insertions, 3 deletions
diff --git a/src/snap.cpp b/src/snap.cpp
index 1e71e7b..273f125 100644
--- a/src/snap.cpp
+++ b/src/snap.cpp
@@ -97,8 +97,8 @@ public:
// force the system to stay awake
std::shared_ptr<ain::Awake> awake;
- if (calendar_bubbles_enabled()) {
- awake = std::make_shared<uin::Awake>(m_engine->app_name());
+ if (appointment.is_ubuntu_alarm() || calendar_bubbles_enabled()) {
+ awake = std::make_shared<ain::Awake>(m_engine->app_name());
}
// calendar events are muted in silent mode; alarm clocks never are
@@ -114,7 +114,7 @@ public:
// create the haptic feedback...
std::shared_ptr<ain::Haptic> haptic;
- if (should_vibrate() && calendar_vibrations_enabled()) {
+ if (should_vibrate() && (appointment.is_ubuntu_alarm() || calendar_vibrations_enabled())) {
const auto haptic_mode = m_settings->alarm_haptic.get();
if (haptic_mode == "pulse")
haptic = std::make_shared<ain::Haptic>(ain::Haptic::MODE_PULSE, appointment.is_ubuntu_alarm());
diff --git a/tests/test-notification.cpp b/tests/test-notification.cpp
index 58c0760..0db6ab9 100644
--- a/tests/test-notification.cpp
+++ b/tests/test-notification.cpp
@@ -230,6 +230,12 @@ TEST_F(NotificationFixture,Response)
};
+ settings->cal_notification_enabled.set(true);
+ settings->cal_notification_sounds.set(true);
+ settings->cal_notification_vibrations.set(true);
+ settings->cal_notification_bubbles.set(true);
+ settings->cal_notification_list.set(true);
+
// walk through the tests
for (const auto& test : tests)
{