| Index: chrome/browser/geolocation/geolocation_permission_context_factory.cc
|
| diff --git a/chrome/browser/geolocation/geolocation_permission_context_factory.cc b/chrome/browser/geolocation/geolocation_permission_context_factory.cc
|
| index 27742b6b43d6ad76ccbc9c720c144d86cb76937a..2f9625b4cca5166158f6f7ce6c45ff6c601385db 100644
|
| --- a/chrome/browser/geolocation/geolocation_permission_context_factory.cc
|
| +++ b/chrome/browser/geolocation/geolocation_permission_context_factory.cc
|
| @@ -6,10 +6,11 @@
|
|
|
| #include "chrome/browser/profiles/incognito_helpers.h"
|
| #include "chrome/browser/profiles/profile.h"
|
| +#include "chrome/common/features.h"
|
| #include "chrome/common/pref_names.h"
|
| #include "components/keyed_service/content/browser_context_dependency_manager.h"
|
| #include "components/pref_registry/pref_registry_syncable.h"
|
| -#if defined(OS_ANDROID)
|
| +#if BUILDFLAG(ANDROID_JAVA_UI)
|
| #include "chrome/browser/geolocation/geolocation_permission_context_android.h"
|
| #else
|
| #include "chrome/browser/geolocation/geolocation_permission_context.h"
|
| @@ -29,7 +30,7 @@ GeolocationPermissionContextFactory::GetInstance() {
|
| return base::Singleton<GeolocationPermissionContextFactory>::get();
|
| }
|
|
|
| -#if !defined(OS_ANDROID)
|
| +#if !BUILDFLAG(ANDROID_JAVA_UI)
|
| GeolocationPermissionContextFactory::GeolocationPermissionContextFactory()
|
| : PermissionContextFactoryBase(
|
| "GeolocationPermissionContext",
|
| @@ -50,7 +51,7 @@ GeolocationPermissionContextFactory::~GeolocationPermissionContextFactory() {
|
| KeyedService*
|
| GeolocationPermissionContextFactory::BuildServiceInstanceFor(
|
| content::BrowserContext* profile) const {
|
| -#if !defined(OS_ANDROID)
|
| +#if !BUILDFLAG(ANDROID_JAVA_UI)
|
| return new GeolocationPermissionContext(static_cast<Profile*>(profile));
|
| #else
|
| return new GeolocationPermissionContextAndroid(
|
| @@ -60,7 +61,7 @@ GeolocationPermissionContextFactory::BuildServiceInstanceFor(
|
|
|
| void GeolocationPermissionContextFactory::RegisterProfilePrefs(
|
| user_prefs::PrefRegistrySyncable* registry) {
|
| -#if defined(OS_ANDROID)
|
| +#if BUILDFLAG(ANDROID_JAVA_UI)
|
| registry->RegisterBooleanPref(prefs::kGeolocationEnabled, true);
|
| #endif
|
| }
|
|
|