diff options
author | joth@chromium.org <joth@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-04-01 11:31:00 +0000 |
---|---|---|
committer | joth@chromium.org <joth@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-04-01 11:31:00 +0000 |
commit | 1642c6086d35b6767c07eca51d23af8ca6d4f3b7 (patch) | |
tree | ce445b2f39cb80f159f4f99e6977851df0bb6cf2 /chrome/browser/geolocation/network_location_provider.h | |
parent | 25212c49c8dff853bb05e52ed4629a8c659004a5 (diff) | |
download | chromium_src-1642c6086d35b6767c07eca51d23af8ca6d4f3b7.zip chromium_src-1642c6086d35b6767c07eca51d23af8ca6d4f3b7.tar.gz chromium_src-1642c6086d35b6767c07eca51d23af8ca6d4f3b7.tar.bz2 |
Defer sending wifi data via the network provider until permission has been granted to use geolocaiton.
Also fixes a long standing todos/bugs that the host sent in the network request was not set correctly, and
location results were not always tagged against the correct source data in the cache.
BUG=39171
TEST=run with --geolocation-enabled and --log-level=0, check from logs that no location request sent until authorized.
Review URL: http://codereview.chromium.org/1541008
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@43339 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/geolocation/network_location_provider.h')
-rw-r--r-- | chrome/browser/geolocation/network_location_provider.h | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/chrome/browser/geolocation/network_location_provider.h b/chrome/browser/geolocation/network_location_provider.h index 93072fa..c03d5c4 100644 --- a/chrome/browser/geolocation/network_location_provider.h +++ b/chrome/browser/geolocation/network_location_provider.h @@ -26,14 +26,14 @@ class NetworkLocationProvider NetworkLocationProvider(AccessTokenStore* access_token_store, URLRequestContextGetter* context, const GURL& url, - const string16& access_token, - const string16& host_name); + const string16& access_token); virtual ~NetworkLocationProvider(); // LocationProviderBase implementation virtual bool StartProvider(); virtual void GetPosition(Geoposition *position); virtual void UpdatePosition(); + virtual void OnPermissionGranted(const GURL& requesting_frame); private: // PositionCache is an implementation detail of NetworkLocationProvider. @@ -52,7 +52,9 @@ class NetworkLocationProvider // NetworkLocationRequest::ListenerInterface implementation. virtual void LocationResponseAvailable(const Geoposition& position, bool server_error, - const string16& access_token); + const string16& access_token, + const RadioData& radio_data, + const WifiData& wifi_data); scoped_refptr<AccessTokenStore> access_token_store_; @@ -78,6 +80,8 @@ class NetworkLocationProvider bool is_new_data_available_; + std::string most_recent_authorized_host_; + // The network location request object, and the url it uses. scoped_ptr<NetworkLocationRequest> request_; |