Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(464)

Unified Diff: chromeos/dbus/system_clock_client.h

Issue 247663003: Date and Time dialog for when the clock isn't synced. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Set Time Dialog Created 6 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
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();

Powered by Google App Engine
This is Rietveld 408576698