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

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

Issue 11179003: Reapply geolocation network protocol changes. (Closed) Base URL: svn://svn.chromium.org/chrome/branches/1271/src/
Patch Set: Created 8 years, 2 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_LOCATION_ARBITRATOR_H_ 5 #ifndef CONTENT_BROWSER_GEOLOCATION_LOCATION_ARBITRATOR_H_
6 #define CONTENT_BROWSER_GEOLOCATION_LOCATION_ARBITRATOR_H_ 6 #define CONTENT_BROWSER_GEOLOCATION_LOCATION_ARBITRATOR_H_
7 7
8 #include "base/memory/scoped_vector.h" 8 #include "base/memory/scoped_vector.h"
9 #include "base/string16.h" 9 #include "base/string16.h"
10 #include "base/time.h" 10 #include "base/time.h"
(...skipping 26 matching lines...) Expand all
37 // (regardles of relative accuracy). Public for tests. 37 // (regardles of relative accuracy). Public for tests.
38 static const int64 kFixStaleTimeoutMilliseconds; 38 static const int64 kFixStaleTimeoutMilliseconds;
39 39
40 // Defines a function that returns the current time. 40 // Defines a function that returns the current time.
41 typedef base::Time (*GetTimeNow)(); 41 typedef base::Time (*GetTimeNow)();
42 42
43 virtual ~GeolocationArbitrator(); 43 virtual ~GeolocationArbitrator();
44 44
45 static GeolocationArbitrator* Create(GeolocationObserver* observer); 45 static GeolocationArbitrator* Create(GeolocationObserver* observer);
46 46
47 static GURL DefaultNetworkProviderURL();
48
47 // See more details in geolocation_provider. 49 // See more details in geolocation_provider.
48 void StartProviders(const GeolocationObserverOptions& options); 50 void StartProviders(const GeolocationObserverOptions& options);
49 void StopProviders(); 51 void StopProviders();
50 52
51 // Called everytime permission is granted to a page for using geolocation. 53 // Called everytime permission is granted to a page for using geolocation.
52 // This may either be through explicit user action (e.g. responding to the 54 // This may either be through explicit user action (e.g. responding to the
53 // infobar prompt) or inferred from a persisted site permission. 55 // infobar prompt) or inferred from a persisted site permission.
54 // The arbitrator will inform all providers of this, which may in turn use 56 // The arbitrator will inform all providers of this, which may in turn use
55 // this information to modify their internal policy. 57 // this information to modify their internal policy.
56 void OnPermissionGranted(); 58 void OnPermissionGranted();
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
94 // The provider which supplied the current |position_| 96 // The provider which supplied the current |position_|
95 const LocationProviderBase* position_provider_; 97 const LocationProviderBase* position_provider_;
96 bool is_permission_granted_; 98 bool is_permission_granted_;
97 // The current best estimate of our position. 99 // The current best estimate of our position.
98 content::Geoposition position_; 100 content::Geoposition position_;
99 101
100 DISALLOW_COPY_AND_ASSIGN(GeolocationArbitrator); 102 DISALLOW_COPY_AND_ASSIGN(GeolocationArbitrator);
101 }; 103 };
102 104
103 #endif // CONTENT_BROWSER_GEOLOCATION_LOCATION_ARBITRATOR_H_ 105 #endif // CONTENT_BROWSER_GEOLOCATION_LOCATION_ARBITRATOR_H_
OLDNEW
« no previous file with comments | « chrome/browser/geolocation/chrome_access_token_store.cc ('k') | content/browser/geolocation/location_arbitrator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698