Chromium Code Reviews| Index: content/browser/geolocation/location_arbitrator_impl.h |
| diff --git a/content/browser/geolocation/location_arbitrator_impl.h b/content/browser/geolocation/location_arbitrator_impl.h |
| index 54ce5a710edb67a7651b09a9a54dd7842a54ba9c..8fa10880bb1f90e48f8610b79bd80c20d116721b 100644 |
| --- a/content/browser/geolocation/location_arbitrator_impl.h |
| +++ b/content/browser/geolocation/location_arbitrator_impl.h |
| @@ -17,6 +17,7 @@ |
| #include "content/browser/geolocation/location_arbitrator.h" |
| #include "content/common/content_export.h" |
| #include "content/public/browser/access_token_store.h" |
| +#include "content/public/browser/geolocation_provider.h" |
| #include "content/public/browser/location_provider.h" |
| #include "content/public/common/geoposition.h" |
| #include "net/url_request/url_request_context_getter.h" |
| @@ -41,7 +42,10 @@ class CONTENT_EXPORT LocationArbitratorImpl : public LocationArbitrator { |
| typedef base::Callback<void(const Geoposition&)> LocationUpdateCallback; |
| - explicit LocationArbitratorImpl(const LocationUpdateCallback& callback); |
| + // Takes ownership of |service_overrides|. |
|
Michael van Ouwerkerk
2016/06/24 13:57:19
I think that a) taking ownership should be express
mcasas
2016/06/24 19:25:52
Yes, I was just lazy -- and I thought I'd be getti
|
| + LocationArbitratorImpl( |
| + const LocationUpdateCallback& callback, |
| + GeolocationProvider::ServiceOverrides* service_overrides); |
| ~LocationArbitratorImpl() override; |
| static GURL DefaultNetworkProviderURL(); |
| @@ -66,6 +70,10 @@ class CONTENT_EXPORT LocationArbitratorImpl : public LocationArbitrator { |
| virtual std::unique_ptr<LocationProvider> NewSystemLocationProvider(); |
| virtual base::Time GetTimeNow() const; |
| + GeolocationProvider::ServiceOverrides* GetServiceOverridesForTesting() { |
| + return service_overrides_.get(); |
| + } |
| + |
| private: |
| // Provider will either be added to |providers_| or |
| // deleted on error (e.g. it fails to start). |
| @@ -88,6 +96,8 @@ class CONTENT_EXPORT LocationArbitratorImpl : public LocationArbitrator { |
| const Geoposition& new_position, |
| bool from_same_provider) const; |
| + std::unique_ptr<GeolocationProvider::ServiceOverrides> service_overrides_; |
| + |
| scoped_refptr<AccessTokenStore> access_token_store_; |
| LocationUpdateCallback arbitrator_update_callback_; |
| LocationProvider::LocationProviderUpdateCallback provider_update_callback_; |