| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "content/browser/geolocation/network_location_request.h" | 5 #include "content/browser/geolocation/network_location_request.h" |
| 6 | 6 |
| 7 #include <stdint.h> | 7 #include <stdint.h> |
| 8 | 8 |
| 9 #include <limits> | 9 #include <limits> |
| 10 #include <set> | 10 #include <set> |
| (...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 96 Geoposition* position, | 96 Geoposition* position, |
| 97 base::string16* access_token); | 97 base::string16* access_token); |
| 98 void AddWifiData(const WifiData& wifi_data, | 98 void AddWifiData(const WifiData& wifi_data, |
| 99 int age_milliseconds, | 99 int age_milliseconds, |
| 100 base::DictionaryValue* request); | 100 base::DictionaryValue* request); |
| 101 } // namespace | 101 } // namespace |
| 102 | 102 |
| 103 int NetworkLocationRequest::url_fetcher_id_for_tests = 0; | 103 int NetworkLocationRequest::url_fetcher_id_for_tests = 0; |
| 104 | 104 |
| 105 NetworkLocationRequest::NetworkLocationRequest( | 105 NetworkLocationRequest::NetworkLocationRequest( |
| 106 net::URLRequestContextGetter* context, | 106 const scoped_refptr<net::URLRequestContextGetter>& context, |
| 107 const GURL& url, | 107 const GURL& url, |
| 108 LocationResponseCallback callback) | 108 LocationResponseCallback callback) |
| 109 : url_context_(context), location_response_callback_(callback), url_(url) { | 109 : url_context_(context), location_response_callback_(callback), url_(url) { |
| 110 } | 110 } |
| 111 | 111 |
| 112 NetworkLocationRequest::~NetworkLocationRequest() { | 112 NetworkLocationRequest::~NetworkLocationRequest() { |
| 113 } | 113 } |
| 114 | 114 |
| 115 bool NetworkLocationRequest::MakeRequest(const base::string16& access_token, | 115 bool NetworkLocationRequest::MakeRequest(const base::string16& access_token, |
| 116 const WifiData& wifi_data, | 116 const WifiData& wifi_data, |
| (...skipping 301 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 418 | 418 |
| 419 // Other fields are optional. | 419 // Other fields are optional. |
| 420 GetAsDouble(*response_object, kAccuracyString, &position->accuracy); | 420 GetAsDouble(*response_object, kAccuracyString, &position->accuracy); |
| 421 | 421 |
| 422 return true; | 422 return true; |
| 423 } | 423 } |
| 424 | 424 |
| 425 } // namespace | 425 } // namespace |
| 426 | 426 |
| 427 } // namespace content | 427 } // namespace content |
| OLD | NEW |