From 7ac0160b0e7ce9245e13750429790cb2a999528b Mon Sep 17 00:00:00 2001 From: Charles Kerr Date: Sat, 9 Apr 2016 19:03:57 -0500 Subject: in actions-live, don't hardcode the bus strings --- src/actions-live.cpp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'src/actions-live.cpp') diff --git a/src/actions-live.cpp b/src/actions-live.cpp index 231fb33..e3237b7 100644 --- a/src/actions-live.cpp +++ b/src/actions-live.cpp @@ -17,6 +17,7 @@ * Charles Kerr */ +#include #include #ifdef HAS_URLDISPATCHER @@ -240,7 +241,7 @@ on_datetime1_proxy_ready (GObject * object G_GNUC_UNUSED, else { g_dbus_proxy_call(proxy, - "SetTimezone", + Bus::Timedate1::Methods::SET_TIMEZONE, g_variant_new ("(sb)", data->tzid.c_str(), TRUE), G_DBUS_CALL_FLAGS_NONE, -1, @@ -268,9 +269,9 @@ void LiveActions::set_location(const std::string& tzid, const std::string& name) g_dbus_proxy_new_for_bus (G_BUS_TYPE_SYSTEM, G_DBUS_PROXY_FLAGS_NONE, nullptr, - "org.freedesktop.timedate1", - "/org/freedesktop/timedate1", - "org.freedesktop.timedate1", + Bus::Timedate1::BUSNAME, + Bus::Timedate1::ADDR, + Bus::Timedate1::IFACE, nullptr, on_datetime1_proxy_ready, data); -- cgit v1.2.3