| 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 "chrome/browser/push_messaging/push_messaging_service_impl.h" | 5 #include "chrome/browser/push_messaging/push_messaging_service_impl.h" |
| 6 | 6 |
| 7 #include <vector> | 7 #include <vector> |
| 8 | 8 |
| 9 #include "base/barrier_closure.h" | 9 #include "base/barrier_closure.h" |
| 10 #include "base/base64url.h" | 10 #include "base/base64url.h" |
| 11 #include "base/bind.h" | 11 #include "base/bind.h" |
| 12 #include "base/bind_helpers.h" | 12 #include "base/bind_helpers.h" |
| 13 #include "base/callback_helpers.h" | 13 #include "base/callback_helpers.h" |
| 14 #include "base/command_line.h" | 14 #include "base/command_line.h" |
| 15 #include "base/feature_list.h" | 15 #include "base/feature_list.h" |
| 16 #include "base/logging.h" | 16 #include "base/logging.h" |
| 17 #include "base/metrics/histogram.h" | 17 #include "base/metrics/histogram_macros.h" |
| 18 #include "build/build_config.h" | 18 #include "build/build_config.h" |
| 19 #include "chrome/browser/browser_process.h" | 19 #include "chrome/browser/browser_process.h" |
| 20 #include "chrome/browser/content_settings/host_content_settings_map_factory.h" | 20 #include "chrome/browser/content_settings/host_content_settings_map_factory.h" |
| 21 #include "chrome/browser/permissions/permission_manager.h" | 21 #include "chrome/browser/permissions/permission_manager.h" |
| 22 #include "chrome/browser/profiles/profile.h" | 22 #include "chrome/browser/profiles/profile.h" |
| 23 #include "chrome/browser/push_messaging/push_messaging_app_identifier.h" | 23 #include "chrome/browser/push_messaging/push_messaging_app_identifier.h" |
| 24 #include "chrome/browser/push_messaging/push_messaging_constants.h" | 24 #include "chrome/browser/push_messaging/push_messaging_constants.h" |
| 25 #include "chrome/browser/push_messaging/push_messaging_service_factory.h" | 25 #include "chrome/browser/push_messaging/push_messaging_service_factory.h" |
| 26 #include "chrome/browser/push_messaging/push_messaging_service_observer.h" | 26 #include "chrome/browser/push_messaging/push_messaging_service_observer.h" |
| 27 #include "chrome/browser/services/gcm/gcm_profile_service_factory.h" | 27 #include "chrome/browser/services/gcm/gcm_profile_service_factory.h" |
| (...skipping 771 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 799 blink::WebPushPermissionStatusGranted; | 799 blink::WebPushPermissionStatusGranted; |
| 800 } | 800 } |
| 801 | 801 |
| 802 gcm::GCMDriver* PushMessagingServiceImpl::GetGCMDriver() const { | 802 gcm::GCMDriver* PushMessagingServiceImpl::GetGCMDriver() const { |
| 803 gcm::GCMProfileService* gcm_profile_service = | 803 gcm::GCMProfileService* gcm_profile_service = |
| 804 gcm::GCMProfileServiceFactory::GetForProfile(profile_); | 804 gcm::GCMProfileServiceFactory::GetForProfile(profile_); |
| 805 CHECK(gcm_profile_service); | 805 CHECK(gcm_profile_service); |
| 806 CHECK(gcm_profile_service->driver()); | 806 CHECK(gcm_profile_service->driver()); |
| 807 return gcm_profile_service->driver(); | 807 return gcm_profile_service->driver(); |
| 808 } | 808 } |
| OLD | NEW |