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

Unified Diff: blimp/engine/app/blimp_content_browser_client.cc

Issue 2126893003: Geolocation cleanup: make GeolocationDelegate::OverrideSystemLocationProvider return unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: wez@ nit Created 4 years, 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | content/browser/geolocation/location_arbitrator_impl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: blimp/engine/app/blimp_content_browser_client.cc
diff --git a/blimp/engine/app/blimp_content_browser_client.cc b/blimp/engine/app/blimp_content_browser_client.cc
index 6c4f55229bcec8eab63f8214196cc550adee61bd..90ea2f52e4c78637305c63ea9346ec75d5085f3b 100644
--- a/blimp/engine/app/blimp_content_browser_client.cc
+++ b/blimp/engine/app/blimp_content_browser_client.cc
@@ -21,15 +21,12 @@ class BlimpGeolocationDelegate : public content::GeolocationDelegate {
bool UseNetworkLocationProviders() final { return false; }
- content::LocationProvider* OverrideSystemLocationProvider() final {
- if (!location_provider_)
- location_provider_ = base::WrapUnique(new BlimpLocationProvider());
- return location_provider_.get();
+ std::unique_ptr<content::LocationProvider> OverrideSystemLocationProvider()
+ final {
+ return base::WrapUnique(new BlimpLocationProvider());
}
private:
- std::unique_ptr<BlimpLocationProvider> location_provider_;
-
DISALLOW_COPY_AND_ASSIGN(BlimpGeolocationDelegate);
};
« no previous file with comments | « no previous file | content/browser/geolocation/location_arbitrator_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698