Index: chromeos/dbus/system_clock_client.h |
diff --git a/chromeos/dbus/system_clock_client.h b/chromeos/dbus/system_clock_client.h |
index 849612db46b8b8f6368c3f48a515e19d0d8eb1a0..a9e1492773070df01d154a7e27180867ea9d20bc 100644 |
--- a/chromeos/dbus/system_clock_client.h |
+++ b/chromeos/dbus/system_clock_client.h |
@@ -5,6 +5,7 @@ |
#ifndef CHROMEOS_DBUS_SYSTEM_CLOCK_CLIENT_H_ |
#define CHROMEOS_DBUS_SYSTEM_CLOCK_CLIENT_H_ |
+#include "base/callback.h" |
#include "base/observer_list.h" |
#include "chromeos/chromeos_export.h" |
#include "chromeos/dbus/dbus_client.h" |
@@ -18,7 +19,11 @@ class CHROMEOS_EXPORT SystemClockClient : public DBusClient { |
class Observer { |
public: |
// Called when the status is updated. |
- virtual void SystemClockUpdated() {} |
+ virtual void SystemClockUpdated(); |
+ |
+ // Called when the system clock has become settable or unsettable, e.g., |
+ // when the clock syncs with or goes out of sync with the network. |
+ virtual void SystemClockCanSetTimeChanged(bool can_set_time); |
protected: |
virtual ~Observer() {} |
}; |
@@ -31,6 +36,12 @@ class CHROMEOS_EXPORT SystemClockClient : public DBusClient { |
// Returns true if this object has the given observer. |
virtual bool HasObserver(Observer* observer) = 0; |
+ // Sets the system clock. |
+ virtual void SetTime(int64 time_in_seconds) = 0; |
Daniel Erat
2014/04/23 16:33:22
use base::Time instead of int64
michaelpg
2014/04/24 01:32:23
Hmm. I would need to get "time in seconds since th
|
+ |
+ // Checks if the system time can be set. |
+ virtual bool CanSetTime() = 0; |
+ |
// Creates the instance. |
static SystemClockClient* Create(); |