Move GeolocationPermissionContext to //components/permissions
This breaks out embedder-specific logic into a Delegate class which is
implemented in //chrome. The Delegate can then be passed to the
GeolocationPermissionContext in the constructor.
This is the first permission context moved to //components/permissions.
I created a new subdirectory there (contexts/), so we can separate DEPS
that are only needed for permission contexts from DEPS needed for the
core permissions code.
All the unit tests were moved except for a couple that were specific
to the //chrome version of the delegate.
Bug: 1025609, 1025625
Change-Id: I98cf85e4b7b51d421d0101d27a6ae1bf60594b27
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2109247
Reviewed-by: Andy Paicu <[email protected]>
Reviewed-by: Ted Choc <[email protected]>
Reviewed-by: Ken Rockot <[email protected]>
Reviewed-by: Gabriel Charette <[email protected]>
Commit-Queue: Clark DuVall <[email protected]>
Cr-Commit-Position: refs/heads/master@{#752458}
diff --git a/chrome/browser/prefs/browser_prefs.cc b/chrome/browser/prefs/browser_prefs.cc
index 06574f3..c0467563 100644
--- a/chrome/browser/prefs/browser_prefs.cc
+++ b/chrome/browser/prefs/browser_prefs.cc
@@ -215,7 +215,6 @@
#include "chrome/browser/android/oom_intervention/oom_intervention_decider.h"
#include "chrome/browser/android/preferences/browser_prefs_android.h"
#include "chrome/browser/android/usage_stats/usage_stats_bridge.h"
-#include "chrome/browser/geolocation/geolocation_permission_context_android.h"
#include "chrome/browser/media/android/cdm/media_drm_origin_id_manager.h"
#include "chrome/browser/ssl/known_interception_disclosure_infobar_delegate.h"
#include "components/cdm/browser/media_drm_storage_impl.h"
@@ -224,6 +223,7 @@
#include "components/games/core/games_prefs.h"
#include "components/ntp_snippets/category_rankers/click_based_category_ranker.h"
#include "components/ntp_tiles/popular_sites_impl.h"
+#include "components/permissions/contexts/geolocation_permission_context_android.h"
#if BUILDFLAG(ENABLE_FEED_IN_CHROME)
#include "components/feed/core/common/pref_names.h"
#endif // BUILDFLAG(ENABLE_FEED_IN_CHROME)
@@ -959,7 +959,8 @@
cdm::MediaDrmStorageImpl::RegisterProfilePrefs(registry);
explore_sites::HistoryStatisticsReporter::RegisterPrefs(registry);
games::prefs::RegisterProfilePrefs(registry);
- GeolocationPermissionContextAndroid::RegisterProfilePrefs(registry);
+ permissions::GeolocationPermissionContextAndroid::RegisterProfilePrefs(
+ registry);
KnownInterceptionDisclosureInfoBarDelegate::RegisterProfilePrefs(registry);
MediaDrmOriginIdManager::RegisterProfilePrefs(registry);
NotificationChannelsProviderAndroid::RegisterProfilePrefs(registry);