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

Side by Side Diff: components/gcm_driver/fake_gcm_client.cc

Issue 1126233004: Persist Instance ID data to GCM store. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix mac Created 5 years, 7 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 unified diff | Download patch
« no previous file with comments | « components/gcm_driver/fake_gcm_client.h ('k') | components/gcm_driver/fake_gcm_driver.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "components/gcm_driver/fake_gcm_client.h" 5 #include "components/gcm_driver/fake_gcm_client.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/logging.h" 8 #include "base/logging.h"
9 #include "base/message_loop/message_loop.h" 9 #include "base/message_loop/message_loop.h"
10 #include "base/sequenced_task_runner.h" 10 #include "base/sequenced_task_runner.h"
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after
130 130
131 void FakeGCMClient::RemoveAccountMapping(const std::string& account_id) { 131 void FakeGCMClient::RemoveAccountMapping(const std::string& account_id) {
132 } 132 }
133 133
134 void FakeGCMClient::SetLastTokenFetchTime(const base::Time& time) { 134 void FakeGCMClient::SetLastTokenFetchTime(const base::Time& time) {
135 } 135 }
136 136
137 void FakeGCMClient::UpdateHeartbeatTimer(scoped_ptr<base::Timer> timer) { 137 void FakeGCMClient::UpdateHeartbeatTimer(scoped_ptr<base::Timer> timer) {
138 } 138 }
139 139
140 void FakeGCMClient::AddInstanceIDData(const std::string& app_id,
141 const std::string& instance_id_data) {
142 }
143
144 void FakeGCMClient::RemoveInstanceIDData(const std::string& app_id) {
145 }
146
147 std::string FakeGCMClient::GetInstanceIDData(const std::string& app_id) {
148 return std::string();
149 }
150
140 void FakeGCMClient::PerformDelayedStart() { 151 void FakeGCMClient::PerformDelayedStart() {
141 DCHECK(ui_thread_->RunsTasksOnCurrentThread()); 152 DCHECK(ui_thread_->RunsTasksOnCurrentThread());
142 153
143 io_thread_->PostTask( 154 io_thread_->PostTask(
144 FROM_HERE, 155 FROM_HERE,
145 base::Bind(&FakeGCMClient::DoStart, weak_ptr_factory_.GetWeakPtr())); 156 base::Bind(&FakeGCMClient::DoStart, weak_ptr_factory_.GetWeakPtr()));
146 } 157 }
147 158
148 void FakeGCMClient::ReceiveMessage(const std::string& app_id, 159 void FakeGCMClient::ReceiveMessage(const std::string& app_id,
149 const IncomingMessage& message) { 160 const IncomingMessage& message) {
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after
250 delegate_->OnMessageSendError(app_id, send_error_details); 261 delegate_->OnMessageSendError(app_id, send_error_details);
251 } 262 }
252 263
253 void FakeGCMClient::SendAcknowledgement(const std::string& app_id, 264 void FakeGCMClient::SendAcknowledgement(const std::string& app_id,
254 const std::string& message_id) { 265 const std::string& message_id) {
255 if (delegate_) 266 if (delegate_)
256 delegate_->OnSendAcknowledged(app_id, message_id); 267 delegate_->OnSendAcknowledged(app_id, message_id);
257 } 268 }
258 269
259 } // namespace gcm 270 } // namespace gcm
OLDNEW
« no previous file with comments | « components/gcm_driver/fake_gcm_client.h ('k') | components/gcm_driver/fake_gcm_driver.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698