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

Unified Diff: components/gcm_driver/instance_id/fake_gcm_driver_for_instance_id.cc

Issue 1851423003: Make Web Push use InstanceID tokens instead of GCM registrations (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@iid4default
Patch Set: Address review comments, and rewrite following rebase (e.g. no longer depends on NestedMessagePumpA… Created 4 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: components/gcm_driver/instance_id/fake_gcm_driver_for_instance_id.cc
diff --git a/components/gcm_driver/instance_id/fake_gcm_driver_for_instance_id.cc b/components/gcm_driver/instance_id/fake_gcm_driver_for_instance_id.cc
index b62270b187daab4f3ae08e71a890515d9bd64e06..c0db85ffb15cb2234fafc079053cfa0317168c8c 100644
--- a/components/gcm_driver/instance_id/fake_gcm_driver_for_instance_id.cc
+++ b/components/gcm_driver/instance_id/fake_gcm_driver_for_instance_id.cc
@@ -17,6 +17,10 @@ namespace instance_id {
FakeGCMDriverForInstanceID::FakeGCMDriverForInstanceID() {
}
+FakeGCMDriverForInstanceID::FakeGCMDriverForInstanceID(
+ const scoped_refptr<base::SequencedTaskRunner>& blocking_task_runner)
+ : FakeGCMDriver(blocking_task_runner) {}
+
FakeGCMDriverForInstanceID::~FakeGCMDriverForInstanceID() {
}
@@ -67,6 +71,9 @@ void FakeGCMDriverForInstanceID::GetToken(
tokens_[key] = token;
}
+ last_registered_app_id_ = app_id;
+ last_registered_authorized_entity_ = authorized_entity;
+
base::ThreadTaskRunnerHandle::Get()->PostTask(
FROM_HERE, base::Bind(callback, token, gcm::GCMClient::SUCCESS));
}

Powered by Google App Engine
This is Rietveld 408576698