Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(266)

Side by Side Diff: content/browser/geolocation/network_location_request.h

Issue 10412050: Change most content::URLFetcher references to net::URLFetcher (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix indent and typo Created 8 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 #ifndef CONTENT_BROWSER_GEOLOCATION_NETWORK_LOCATION_REQUEST_H_ 5 #ifndef CONTENT_BROWSER_GEOLOCATION_NETWORK_LOCATION_REQUEST_H_
6 #define CONTENT_BROWSER_GEOLOCATION_NETWORK_LOCATION_REQUEST_H_ 6 #define CONTENT_BROWSER_GEOLOCATION_NETWORK_LOCATION_REQUEST_H_
7 #pragma once 7 #pragma once
8 8
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "base/memory/ref_counted.h" 10 #include "base/memory/ref_counted.h"
11 #include "base/memory/scoped_ptr.h" 11 #include "base/memory/scoped_ptr.h"
12 #include "content/browser/geolocation/device_data_provider.h" 12 #include "content/browser/geolocation/device_data_provider.h"
13 #include "content/common/content_export.h" 13 #include "content/common/content_export.h"
14 #include "googleurl/src/gurl.h" 14 #include "googleurl/src/gurl.h"
15 #include "net/url_request/url_fetcher_delegate.h" 15 #include "net/url_request/url_fetcher_delegate.h"
16 16
17 namespace content { 17 namespace content {
18 struct Geoposition; 18 struct Geoposition;
19 class URLFetcher; 19 class URLFetcher;
wtc 2012/05/23 01:34:01 Delete this forward declaration, or rather, forwar
akalin 2012/05/23 04:33:09 Done.
20 } 20 }
21 21
22 namespace net { 22 namespace net {
23 class URLRequestContextGetter; 23 class URLRequestContextGetter;
24 } 24 }
25 25
26 // Takes a set of device data and sends it to a server to get a position fix. 26 // Takes a set of device data and sends it to a server to get a position fix.
27 // It performs formatting of the request and interpretation of the response. 27 // It performs formatting of the request and interpretation of the response.
28 class NetworkLocationRequest : private net::URLFetcherDelegate { 28 class NetworkLocationRequest : private net::URLFetcherDelegate {
29 public: 29 public:
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
61 bool is_request_pending() const { return url_fetcher_ != NULL; } 61 bool is_request_pending() const { return url_fetcher_ != NULL; }
62 const GURL& url() const { return url_; } 62 const GURL& url() const { return url_; }
63 63
64 private: 64 private:
65 // net::URLFetcherDelegate 65 // net::URLFetcherDelegate
66 virtual void OnURLFetchComplete(const net::URLFetcher* source) OVERRIDE; 66 virtual void OnURLFetchComplete(const net::URLFetcher* source) OVERRIDE;
67 67
68 scoped_refptr<net::URLRequestContextGetter> url_context_; 68 scoped_refptr<net::URLRequestContextGetter> url_context_;
69 ListenerInterface* listener_; 69 ListenerInterface* listener_;
70 const GURL url_; 70 const GURL url_;
71 scoped_ptr<content::URLFetcher> url_fetcher_; 71 scoped_ptr<net::URLFetcher> url_fetcher_;
72 72
73 // Keep a copy of the data sent in the request, so we can refer back to it 73 // Keep a copy of the data sent in the request, so we can refer back to it
74 // when the response arrives. 74 // when the response arrives.
75 RadioData radio_data_; 75 RadioData radio_data_;
76 WifiData wifi_data_; 76 WifiData wifi_data_;
77 base::Time timestamp_; // Timestamp of the above data, not of the request. 77 base::Time timestamp_; // Timestamp of the above data, not of the request.
78 78
79 DISALLOW_COPY_AND_ASSIGN(NetworkLocationRequest); 79 DISALLOW_COPY_AND_ASSIGN(NetworkLocationRequest);
80 }; 80 };
81 81
82 #endif // CONTENT_BROWSER_GEOLOCATION_NETWORK_LOCATION_REQUEST_H_ 82 #endif // CONTENT_BROWSER_GEOLOCATION_NETWORK_LOCATION_REQUEST_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698