Index: chrome/browser/push_messaging/push_messaging_service_impl.h |
diff --git a/chrome/browser/push_messaging/push_messaging_service_impl.h b/chrome/browser/push_messaging/push_messaging_service_impl.h |
index 343548061f38bcb4cfc388187f9d3457db0c79e9..54ac0ac6e1315dea46c91300af6150c9e08ed94f 100644 |
--- a/chrome/browser/push_messaging/push_messaging_service_impl.h |
+++ b/chrome/browser/push_messaging/push_messaging_service_impl.h |
@@ -20,7 +20,7 @@ |
#include "components/content_settings/core/common/content_settings.h" |
#include "components/gcm_driver/common/gcm_messages.h" |
#include "components/gcm_driver/gcm_app_handler.h" |
-#include "components/gcm_driver/gcm_client.h" |
+#include "components/gcm_driver/instance_id/instance_id.h" |
#include "components/keyed_service/core/keyed_service.h" |
#include "content/public/browser/push_messaging_service.h" |
#include "content/public/common/push_event_payload.h" |
@@ -39,7 +39,9 @@ struct PushSubscriptionOptions; |
namespace gcm { |
class GCMDriver; |
-class GCMProfileService; |
+} |
+namespace instance_id { |
+class InstanceIDDriver; |
} |
namespace user_prefs { |
@@ -92,7 +94,6 @@ class PushMessagingServiceImpl : public content::PushMessagingService, |
void Unsubscribe( |
const GURL& requesting_origin, |
int64_t service_worker_registration_id, |
- const std::string& sender_id, |
const content::PushMessagingService::UnregisterCallback&) override; |
blink::WebPushPermissionStatus GetPermissionStatus( |
const GURL& origin, |
@@ -139,6 +140,12 @@ class PushMessagingServiceImpl : public content::PushMessagingService, |
// Subscribe methods --------------------------------------------------------- |
+ void DoSubscribe( |
+ const PushMessagingAppIdentifier& app_identifier, |
+ const content::PushSubscriptionOptions& options, |
+ const content::PushMessagingService::RegisterCallback& callback, |
+ blink::mojom::PermissionStatus permission_status); |
+ |
void SubscribeEnd( |
const content::PushMessagingService::RegisterCallback& callback, |
const std::string& subscription_id, |
@@ -154,7 +161,7 @@ class PushMessagingServiceImpl : public content::PushMessagingService, |
const PushMessagingAppIdentifier& app_identifier, |
const content::PushMessagingService::RegisterCallback& callback, |
const std::string& subscription_id, |
- gcm::GCMClient::Result result); |
+ instance_id::InstanceID::Result result); |
void DidSubscribeWithEncryptionInfo( |
const PushMessagingAppIdentifier& app_identifier, |
@@ -163,12 +170,6 @@ class PushMessagingServiceImpl : public content::PushMessagingService, |
const std::string& p256dh, |
const std::string& auth_secret); |
- void DidRequestPermission( |
- const PushMessagingAppIdentifier& app_identifier, |
- const content::PushSubscriptionOptions& options, |
- const content::PushMessagingService::RegisterCallback& callback, |
- blink::mojom::PermissionStatus permission_status); |
- |
// GetEncryptionInfo method -------------------------------------------------- |
void DidGetEncryptionInfo( |
@@ -179,21 +180,18 @@ class PushMessagingServiceImpl : public content::PushMessagingService, |
// Unsubscribe methods ------------------------------------------------------- |
void Unsubscribe(const std::string& app_id, |
- const std::string& sender_id, |
const content::PushMessagingService::UnregisterCallback&); |
- void DidUnsubscribe(bool was_subscribed, |
+ void DidUnsubscribe(const std::string& app_id, |
+ bool was_subscribed, |
const content::PushMessagingService::UnregisterCallback&, |
- gcm::GCMClient::Result result); |
+ instance_id::InstanceID::Result result); |
// OnContentSettingChanged methods ------------------------------------------- |
void UnsubscribeBecausePermissionRevoked( |
const PushMessagingAppIdentifier& app_identifier, |
- const base::Closure& closure, |
- const std::string& sender_id, |
- bool success, |
- bool not_found); |
+ const base::Closure& closure); |
// Helper methods ------------------------------------------------------------ |
@@ -207,6 +205,8 @@ class PushMessagingServiceImpl : public content::PushMessagingService, |
gcm::GCMDriver* GetGCMDriver() const; |
+ instance_id::InstanceIDDriver* GetInstanceIDDriver() const; |
+ |
// Testing methods ----------------------------------------------------------- |
// Callback to be invoked when a message has been dispatched. Enables tests to |