| 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 #ifndef CHROMECAST_BROWSER_METRICS_CAST_METRICS_SERVICE_CLIENT_H_ | 5 #ifndef CHROMECAST_BROWSER_METRICS_CAST_METRICS_SERVICE_CLIENT_H_ |
| 6 #define CHROMECAST_BROWSER_METRICS_CAST_METRICS_SERVICE_CLIENT_H_ | 6 #define CHROMECAST_BROWSER_METRICS_CAST_METRICS_SERVICE_CLIENT_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/macros.h" | 10 #include "base/macros.h" |
| (...skipping 30 matching lines...) Expand all Loading... |
| 41 class CastMetricsServiceClient : public ::metrics::MetricsServiceClient { | 41 class CastMetricsServiceClient : public ::metrics::MetricsServiceClient { |
| 42 public: | 42 public: |
| 43 ~CastMetricsServiceClient() override; | 43 ~CastMetricsServiceClient() override; |
| 44 | 44 |
| 45 static scoped_ptr<CastMetricsServiceClient> Create( | 45 static scoped_ptr<CastMetricsServiceClient> Create( |
| 46 base::TaskRunner* io_task_runner, | 46 base::TaskRunner* io_task_runner, |
| 47 PrefService* pref_service, | 47 PrefService* pref_service, |
| 48 net::URLRequestContextGetter* request_context); | 48 net::URLRequestContextGetter* request_context); |
| 49 static void RegisterPrefs(PrefRegistrySimple* registry); | 49 static void RegisterPrefs(PrefRegistrySimple* registry); |
| 50 | 50 |
| 51 void OnApplicationNotIdle(); |
| 51 void Initialize(CastService* cast_service); | 52 void Initialize(CastService* cast_service); |
| 52 void Finalize(); | 53 void Finalize(); |
| 53 | 54 |
| 54 // metrics::MetricsServiceClient implementation: | 55 // metrics::MetricsServiceClient implementation: |
| 55 void SetMetricsClientId(const std::string& client_id) override; | 56 void SetMetricsClientId(const std::string& client_id) override; |
| 56 void OnRecordingDisabled() override; | 57 void OnRecordingDisabled() override; |
| 57 bool IsOffTheRecordSessionActive() override; | 58 bool IsOffTheRecordSessionActive() override; |
| 58 int32_t GetProduct() override; | 59 int32_t GetProduct() override; |
| 59 std::string GetApplicationLocale() override; | 60 std::string GetApplicationLocale() override; |
| 60 bool GetBrand(std::string* brand_code) override; | 61 bool GetBrand(std::string* brand_code) override; |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 97 scoped_ptr< ::metrics::MetricsService> metrics_service_; | 98 scoped_ptr< ::metrics::MetricsService> metrics_service_; |
| 98 net::URLRequestContextGetter* const request_context_; | 99 net::URLRequestContextGetter* const request_context_; |
| 99 | 100 |
| 100 DISALLOW_COPY_AND_ASSIGN(CastMetricsServiceClient); | 101 DISALLOW_COPY_AND_ASSIGN(CastMetricsServiceClient); |
| 101 }; | 102 }; |
| 102 | 103 |
| 103 } // namespace metrics | 104 } // namespace metrics |
| 104 } // namespace chromecast | 105 } // namespace chromecast |
| 105 | 106 |
| 106 #endif // CHROMECAST_BROWSER_METRICS_CAST_METRICS_SERVICE_CLIENT_H_ | 107 #endif // CHROMECAST_BROWSER_METRICS_CAST_METRICS_SERVICE_CLIENT_H_ |
| OLD | NEW |