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

Unified Diff: chrome/browser/android/search_geolocation/search_geolocation_service.cc

Issue 2811073003: Revert of Don't use the DSE geolocation setting when chrome doesn't have location. (Closed)
Patch Set: Created 3 years, 8 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
Index: chrome/browser/android/search_geolocation/search_geolocation_service.cc
diff --git a/chrome/browser/android/search_geolocation/search_geolocation_service.cc b/chrome/browser/android/search_geolocation/search_geolocation_service.cc
index 59f040a689f451345d778fbdf781cef667d085ce..7977997bc388d14e5911407c73c86ad6cbbe28a9 100644
--- a/chrome/browser/android/search_geolocation/search_geolocation_service.cc
+++ b/chrome/browser/android/search_geolocation/search_geolocation_service.cc
@@ -7,7 +7,6 @@
#include "base/callback.h"
#include "base/feature_list.h"
#include "base/values.h"
-#include "chrome/browser/android/location_settings_impl.h"
#include "chrome/browser/android/search_geolocation/search_geolocation_disclosure_tab_helper.h"
#include "chrome/browser/content_settings/host_content_settings_map_factory.h"
#include "chrome/browser/profiles/profile.h"
@@ -135,8 +134,7 @@
: profile_(profile),
pref_service_(profile_->GetPrefs()),
host_content_settings_map_(
- HostContentSettingsMapFactory::GetForProfile(profile_)),
- location_settings_(new LocationSettingsImpl()) {
+ HostContentSettingsMapFactory::GetForProfile(profile_)) {
// This class should never be constructed in incognito.
DCHECK(!profile_->IsOffTheRecord());
@@ -172,9 +170,6 @@
GetCurrentContentSetting() == CONTENT_SETTING_ASK) {
return false;
}
-
- if (!location_settings_->HasAndroidLocationPermission())
- return false;
return true;
}
@@ -324,8 +319,3 @@
delegate_->SetDSEChangedCallback(base::Bind(
&SearchGeolocationService::OnDSEChanged, base::Unretained(this)));
}
-
-void SearchGeolocationService::SetLocationSettingsForTest(
- std::unique_ptr<LocationSettings> settings) {
- location_settings_ = std::move(settings);
-}

Powered by Google App Engine
This is Rietveld 408576698