aboutsummaryrefslogtreecommitdiff
path: root/include/datetime
diff options
context:
space:
mode:
Diffstat (limited to 'include/datetime')
-rw-r--r--include/datetime/dbus-shared.h42
-rw-r--r--include/datetime/timezone-timedated.h6
2 files changed, 44 insertions, 4 deletions
diff --git a/include/datetime/dbus-shared.h b/include/datetime/dbus-shared.h
index 057ac6b..fd43ae8 100644
--- a/include/datetime/dbus-shared.h
+++ b/include/datetime/dbus-shared.h
@@ -28,5 +28,47 @@
#define BUS_POWERD_PATH "/com/canonical/powerd"
#define BUS_POWERD_INTERFACE "com.canonical.powerd"
+namespace ayatana {
+namespace indicator {
+namespace datetime {
+
+namespace Bus
+{
+ namespace Timedate1
+ {
+ static constexpr char const * BUSNAME {"org.freedesktop.timedate1"};
+ static constexpr char const * ADDR {"/org/freedesktop/timedate1"};
+ static constexpr char const * IFACE {"org.freedesktop.timedate1"};
+
+ namespace Properties
+ {
+ static constexpr char const * TIMEZONE {"Timezone"};
+ }
+
+ namespace Methods
+ {
+ static constexpr char const * SET_TIMEZONE {"SetTimezone"};
+ }
+ }
+
+ namespace Properties
+ {
+ static constexpr char const * IFACE {"org.freedesktop.DBus.Properties"};
+
+ namespace Methods
+ {
+ static constexpr char const * GET {"Get"};
+ }
+
+ namespace Signals
+ {
+ static constexpr char const * PROPERTIES_CHANGED {"PropertiesChanged"};
+ }
+ }
+}
+
+} // namespace datetime
+} // namespace indicator
+} // namespace ayatana
#endif /* INDICATOR_DATETIME_DBUS_SHARED_H */
diff --git a/include/datetime/timezone-timedated.h b/include/datetime/timezone-timedated.h
index 336a148..0857706 100644
--- a/include/datetime/timezone-timedated.h
+++ b/include/datetime/timezone-timedated.h
@@ -20,8 +20,6 @@
#ifndef INDICATOR_DATETIME_TIMEDATED_TIMEZONE_H
#define INDICATOR_DATETIME_TIMEDATED_TIMEZONE_H
-#define DEFAULT_FILENAME "/etc/timezone"
-
#include <datetime/timezone.h> // base class
#include <string> // std::string
@@ -31,12 +29,12 @@ namespace indicator {
namespace datetime {
/**
- * \brief A #Timezone that gets its information from monitoring a file, such as /etc/timezone
+ * \brief A #Timezone that gets its information from org.freedesktop.timedate1
*/
class TimedatedTimezone: public Timezone
{
public:
- TimedatedTimezone(std::string filename = DEFAULT_FILENAME);
+ TimedatedTimezone();
~TimedatedTimezone();
private: