From d4210a27d9ed8c519666d219999e98e630cc4e2d Mon Sep 17 00:00:00 2001 From: Robert Tari Date: Thu, 28 Oct 2021 07:27:22 +0200 Subject: Remove com.canonical.usensord and disable haptic --- include/notifications/dbus-shared.h | 9 ++++++--- src/haptic.cpp | 7 +++++-- tests/notification-fixture.h | 4 +++- 3 files changed, 14 insertions(+), 6 deletions(-) diff --git a/include/notifications/dbus-shared.h b/include/notifications/dbus-shared.h index 31df219..ea47328 100644 --- a/include/notifications/dbus-shared.h +++ b/include/notifications/dbus-shared.h @@ -1,5 +1,6 @@ /* * Copyright 2013 Canonical Ltd. + * Copyright 2021 Robert Tari * * This program is free software: you can redistribute it and/or modify it * under the terms of the GNU General Public License version 3, as published @@ -16,6 +17,7 @@ * Authors: * Ted Gould * Charles Kerr + * Robert Tari */ #ifndef AYATANA_INDICATOR_NOTIFICATIONS_DBUS_SHARED_H @@ -29,8 +31,9 @@ #define BUS_POWERD_PATH "/com/lomiri/Repowerd" #define BUS_POWERD_INTERFACE "com.lomiri.Repowerd" -#define BUS_HAPTIC_NAME "com.canonical.usensord" -#define BUS_HAPTIC_PATH "/com/canonical/usensord/haptic" -#define BUS_HAPTIC_INTERFACE "com.canonical.usensord.haptic" +//TODO: Reimplement using hfd-service +//#define BUS_HAPTIC_NAME "" +//#define BUS_HAPTIC_PATH "" +//#define BUS_HAPTIC_INTERFACE "" #endif /* INDICATOR_NOTIFICATIONS_DBUS_SHARED_H */ diff --git a/src/haptic.cpp b/src/haptic.cpp index dc2cb82..d794ba7 100644 --- a/src/haptic.cpp +++ b/src/haptic.cpp @@ -1,5 +1,6 @@ /* * Copyright 2014 Canonical Ltd. + * Copyright 2021 Robert Tari * * This program is free software: you can redistribute it and/or modify it * under the terms of the GNU General Public License version 3, as published @@ -15,6 +16,7 @@ * * Authors: * Charles Kerr + * Robert Tari */ #include @@ -130,7 +132,8 @@ private: g_variant_builder_init (&builder, G_VARIANT_TYPE_TUPLE); g_variant_builder_add_value (&builder, pattern_array); g_variant_builder_add_value (&builder, repeat_count); - auto vibrate_pattern_args = g_variant_builder_end (&builder); + //TODO: Reimplement using hfd-service + /*auto vibrate_pattern_args = g_variant_builder_end (&builder); g_dbus_connection_call (m_bus, BUS_HAPTIC_NAME, @@ -143,7 +146,7 @@ private: -1, m_cancellable, nullptr, - nullptr); + nullptr);*/ } const Mode m_mode; diff --git a/tests/notification-fixture.h b/tests/notification-fixture.h index f94dd69..5024792 100644 --- a/tests/notification-fixture.h +++ b/tests/notification-fixture.h @@ -279,6 +279,8 @@ protected: g_assert_no_error (error); dbus_test_service_add_task(service, DBUS_TEST_TASK(screen_mock)); + //TODO: Reimplement using hfd-service + /* /// /// Add the haptic mock /// @@ -296,7 +298,7 @@ protected: "", &error); g_assert_no_error (error); - dbus_test_service_add_task(service, DBUS_TEST_TASK(haptic_mock)); + dbus_test_service_add_task(service, DBUS_TEST_TASK(haptic_mock));*/ startDbusMock(); } -- cgit v1.2.3