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/services/gcm/gcm_driver.h" | 5 #include "components/gcm_driver/gcm_driver.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <utility> | 8 #include <utility> |
9 | 9 |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
11 #include "base/bind_helpers.h" | 11 #include "base/bind_helpers.h" |
12 #include "base/files/file_path.h" | 12 #include "base/files/file_path.h" |
13 #include "base/location.h" | 13 #include "base/location.h" |
14 #include "base/logging.h" | 14 #include "base/logging.h" |
15 #include "base/sequenced_task_runner.h" | 15 #include "base/sequenced_task_runner.h" |
16 #include "base/threading/sequenced_worker_pool.h" | 16 #include "base/threading/sequenced_worker_pool.h" |
17 #include "chrome/common/chrome_version_info.h" | |
18 #include "components/gcm_driver/gcm_app_handler.h" | 17 #include "components/gcm_driver/gcm_app_handler.h" |
19 #include "components/gcm_driver/gcm_client_factory.h" | 18 #include "components/gcm_driver/gcm_client_factory.h" |
20 #include "components/gcm_driver/system_encryptor.h" | 19 #include "components/gcm_driver/system_encryptor.h" |
21 #include "google_apis/gaia/oauth2_token_service.h" | 20 #include "google_apis/gaia/oauth2_token_service.h" |
22 #include "net/url_request/url_request_context_getter.h" | 21 #include "net/url_request/url_request_context_getter.h" |
23 | 22 |
24 namespace gcm { | 23 namespace gcm { |
25 | 24 |
26 // Helper class to save tasks to run until we're ready to execute them. | 25 // Helper class to save tasks to run until we're ready to execute them. |
27 class GCMDriver::DelayedTaskController { | 26 class GCMDriver::DelayedTaskController { |
(...skipping 785 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
813 LOG(WARNING) << "request_gcm_statistics_callback_ is NULL."; | 812 LOG(WARNING) << "request_gcm_statistics_callback_ is NULL."; |
814 } | 813 } |
815 | 814 |
816 std::string GCMDriver::SignedInUserName() const { | 815 std::string GCMDriver::SignedInUserName() const { |
817 if (IsStarted()) | 816 if (IsStarted()) |
818 return identity_provider_->GetActiveUsername(); | 817 return identity_provider_->GetActiveUsername(); |
819 return std::string(); | 818 return std::string(); |
820 } | 819 } |
821 | 820 |
822 } // namespace gcm | 821 } // namespace gcm |
OLD | NEW |