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

Unified Diff: chrome/browser/browsing_data/browsing_data_counter_factory.cc

Issue 2816723002: Add "Site Settings" option to Clear Browsing Data on Android (Closed)
Patch Set: fix deps Created 3 years, 7 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/browsing_data/browsing_data_counter_factory.cc
diff --git a/chrome/browser/browsing_data/browsing_data_counter_factory.cc b/chrome/browser/browsing_data/browsing_data_counter_factory.cc
index 2b9f452a0b08cf1a7539914244f175afe3206a59..41216b82d1dfd255fa307f373b2f25433ec0fe8f 100644
--- a/chrome/browser/browsing_data/browsing_data_counter_factory.cc
+++ b/chrome/browser/browsing_data/browsing_data_counter_factory.cc
@@ -12,6 +12,7 @@
#include "chrome/browser/browsing_data/downloads_counter.h"
#include "chrome/browser/browsing_data/media_licenses_counter.h"
#include "chrome/browser/browsing_data/site_data_counter.h"
+#include "chrome/browser/content_settings/host_content_settings_map_factory.h"
#include "chrome/browser/history/history_service_factory.h"
#include "chrome/browser/history/web_history_service_factory.h"
#include "chrome/browser/password_manager/password_store_factory.h"
@@ -23,6 +24,7 @@
#include "components/browsing_data/core/counters/browsing_data_counter.h"
#include "components/browsing_data/core/counters/history_counter.h"
#include "components/browsing_data/core/counters/passwords_counter.h"
+#include "components/browsing_data/core/counters/site_settings_counter.h"
#include "components/browsing_data/core/pref_names.h"
#include "components/history/core/browser/web_history_service.h"
#include "components/password_manager/core/browser/password_store.h"
@@ -94,6 +96,11 @@ BrowsingDataCounterFactory::GetForProfileAndPref(Profile* profile,
if (pref_name == browsing_data::prefs::kDeleteMediaLicenses)
return base::MakeUnique<MediaLicensesCounter>(profile);
+ if (pref_name == browsing_data::prefs::kDeleteSiteSettings) {
+ return base::MakeUnique<browsing_data::SiteSettingsCounter>(
+ HostContentSettingsMapFactory::GetForProfile(profile));
+ }
+
#if BUILDFLAG(ENABLE_EXTENSIONS)
if (pref_name == browsing_data::prefs::kDeleteHostedAppsData)
return base::MakeUnique<HostedAppsCounter>(profile);

Powered by Google App Engine
This is Rietveld 408576698