Index: chrome/browser/extensions/api/gcm/gcm_api.h |
diff --git a/chrome/browser/extensions/api/gcm/gcm_api.h b/chrome/browser/extensions/api/gcm/gcm_api.h |
index 964a6ea1a2b17bd6b2234f6e8a55ff2b28d7089c..71c73d155eb507efaacf9ef2b5e0b2444b78cf3c 100644 |
--- a/chrome/browser/extensions/api/gcm/gcm_api.h |
+++ b/chrome/browser/extensions/api/gcm/gcm_api.h |
@@ -7,6 +7,7 @@ |
#include "chrome/browser/services/gcm/gcm_event_router.h" |
#include "chrome/common/extensions/api/gcm.h" |
+#include "extensions/browser/event_router.h" |
#include "extensions/browser/extension_function.h" |
#include "google_apis/gcm/gcm_client.h" |
@@ -75,7 +76,8 @@ class GcmSendFunction : public GcmApiFunction { |
bool ValidateMessageData(const gcm::GCMClient::MessageData& data) const; |
}; |
-class GcmJsEventRouter : public gcm::GCMEventRouter { |
+class GcmJsEventRouter : public gcm::GCMEventRouter, |
+ public EventRouter::Observer { |
public: |
explicit GcmJsEventRouter(Profile* profile); |
@@ -90,6 +92,9 @@ class GcmJsEventRouter : public gcm::GCMEventRouter { |
const std::string& message_id, |
gcm::GCMClient::Result result) OVERRIDE; |
+ // EventRouter::Observer: |
+ virtual void OnListenerAdded(const EventListenerInfo& details) OVERRIDE; |
+ |
private: |
// The application we route the event to is running in context of the |
// |profile_| and the latter outlives the event router. |