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

Unified Diff: sync/notifier/chrome_invalidation_client.h

Issue 10916131: [Invalidations] Add GetInvalidatorState() to Invalidator{,Frontend} (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix compile error Created 8 years, 3 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: sync/notifier/chrome_invalidation_client.h
diff --git a/sync/notifier/chrome_invalidation_client.h b/sync/notifier/chrome_invalidation_client.h
index 1d2d33d424e3138f9f5720caab33e2c8d27898d2..3172d09325959f934feda68690e41d789642844d 100644
--- a/sync/notifier/chrome_invalidation_client.h
+++ b/sync/notifier/chrome_invalidation_client.h
@@ -21,7 +21,7 @@
#include "sync/internal_api/public/util/weak_handle.h"
#include "sync/notifier/chrome_system_resources.h"
#include "sync/notifier/invalidation_state_tracker.h"
-#include "sync/notifier/notifications_disabled_reason.h"
+#include "sync/notifier/invalidator_state.h"
#include "sync/notifier/object_id_state_map.h"
#include "sync/notifier/state_writer.h"
@@ -58,10 +58,7 @@ class ChromeInvalidationClient
virtual void OnInvalidate(const ObjectIdStateMap& id_state_map) = 0;
- virtual void OnNotificationsEnabled() = 0;
-
- virtual void OnNotificationsDisabled(
- NotificationsDisabledReason reason) = 0;
+ virtual void OnInvalidatorStateChange(InvalidatorState state) = 0;
};
explicit ChromeInvalidationClient(
@@ -135,7 +132,7 @@ class ChromeInvalidationClient
private:
void Stop();
- NotificationsDisabledReason GetState() const;
+ InvalidatorState GetState() const;
void EmitStateChange();
@@ -152,10 +149,9 @@ class ChromeInvalidationClient
// Stored to pass to |registration_manager_| on start.
ObjectIdSet registered_ids_;
- // The states of the ticl and the push client (with
- // NO_NOTIFICATION_ERROR meaning notifications are enabled).
- NotificationsDisabledReason ticl_state_;
- NotificationsDisabledReason push_client_state_;
+ // The states of the ticl and the push client.
+ InvalidatorState ticl_state_;
+ InvalidatorState push_client_state_;
DISALLOW_COPY_AND_ASSIGN(ChromeInvalidationClient);
};

Powered by Google App Engine
This is Rietveld 408576698