OLD | NEW |
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 "content/browser/push_messaging/push_messaging_manager.h" | 5 #include "content/browser/push_messaging/push_messaging_manager.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
(...skipping 250 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
261 | 261 |
262 if (service_available_) { | 262 if (service_available_) { |
263 default_endpoint_ = service->GetEndpoint(false /* standard_protocol */); | 263 default_endpoint_ = service->GetEndpoint(false /* standard_protocol */); |
264 web_push_protocol_endpoint_ = | 264 web_push_protocol_endpoint_ = |
265 service->GetEndpoint(true /* standard_protocol */); | 265 service->GetEndpoint(true /* standard_protocol */); |
266 } | 266 } |
267 } | 267 } |
268 | 268 |
269 PushMessagingManager::~PushMessagingManager() {} | 269 PushMessagingManager::~PushMessagingManager() {} |
270 | 270 |
271 void PushMessagingManager::BindRequest(mojom::PushMessagingRequest request) { | 271 void PushMessagingManager::BindRequest( |
| 272 const service_manager::BindSourceInfo& source_info, |
| 273 mojom::PushMessagingRequest request) { |
272 bindings_.AddBinding(this, std::move(request)); | 274 bindings_.AddBinding(this, std::move(request)); |
273 } | 275 } |
274 | 276 |
275 // Subscribe methods on both IO and UI threads, merged in order of use from | 277 // Subscribe methods on both IO and UI threads, merged in order of use from |
276 // PushMessagingManager and Core. | 278 // PushMessagingManager and Core. |
277 // ----------------------------------------------------------------------------- | 279 // ----------------------------------------------------------------------------- |
278 | 280 |
279 void PushMessagingManager::Subscribe(int32_t render_frame_id, | 281 void PushMessagingManager::Subscribe(int32_t render_frame_id, |
280 int64_t service_worker_registration_id, | 282 int64_t service_worker_registration_id, |
281 const PushSubscriptionOptions& options, | 283 const PushSubscriptionOptions& options, |
(...skipping 749 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1031 : nullptr; | 1033 : nullptr; |
1032 } | 1034 } |
1033 | 1035 |
1034 base::WeakPtr<PushMessagingManager::Core> | 1036 base::WeakPtr<PushMessagingManager::Core> |
1035 PushMessagingManager::Core::GetWeakPtrFromIOParentConstructor() { | 1037 PushMessagingManager::Core::GetWeakPtrFromIOParentConstructor() { |
1036 DCHECK_CURRENTLY_ON(BrowserThread::UI); | 1038 DCHECK_CURRENTLY_ON(BrowserThread::UI); |
1037 return weak_factory_ui_to_ui_.GetWeakPtr(); | 1039 return weak_factory_ui_to_ui_.GetWeakPtr(); |
1038 } | 1040 } |
1039 | 1041 |
1040 } // namespace content | 1042 } // namespace content |
OLD | NEW |