Turn ContentSettingsType into an enum class type.
This is a precursor to defining ContentSettingsType via mojom. That change
will require more work as Clank depends on an Java definition of this type
that is auto-generated from content_settings_types.h.
Change-Id: Ieec565c6332528e6fc5112ad04c675d9b6137f1a
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1885973
Reviewed-by: John Abd-El-Malek <[email protected]>
Reviewed-by: Kinuko Yasuda <[email protected]>
Commit-Queue: Darin Fisher <[email protected]>
Cr-Commit-Position: refs/heads/master@{#710684}
diff --git a/chrome/browser/notifications/web_page_notifier_controller.cc b/chrome/browser/notifications/web_page_notifier_controller.cc
index 1c07723e..bc5ca34 100644
--- a/chrome/browser/notifications/web_page_notifier_controller.cc
+++ b/chrome/browser/notifications/web_page_notifier_controller.cc
@@ -28,7 +28,7 @@
ContentSettingsForOneType settings;
HostContentSettingsMapFactory::GetForProfile(profile)->GetSettingsForOneType(
- CONTENT_SETTINGS_TYPE_NOTIFICATIONS,
+ ContentSettingsType::NOTIFICATIONS,
content_settings::ResourceIdentifier(), &settings);
favicon::FaviconService* const favicon_service =
@@ -52,7 +52,7 @@
NotifierStateTrackerFactory::GetForProfile(profile);
content_settings::SettingInfo info;
HostContentSettingsMapFactory::GetForProfile(profile)->GetWebsiteSetting(
- url, GURL(), CONTENT_SETTINGS_TYPE_NOTIFICATIONS, std::string(), &info);
+ url, GURL(), ContentSettingsType::NOTIFICATIONS, std::string(), &info);
notifiers.emplace_back(
notifier_id, name,
notifier_state_tracker->IsNotifierEnabled(notifier_id),
@@ -81,7 +81,7 @@
// TODO(mukai): fix this.
ContentSetting default_setting =
HostContentSettingsMapFactory::GetForProfile(profile)
- ->GetDefaultContentSetting(CONTENT_SETTINGS_TYPE_NOTIFICATIONS, NULL);
+ ->GetDefaultContentSetting(ContentSettingsType::NOTIFICATIONS, NULL);
DCHECK(default_setting == CONTENT_SETTING_ALLOW ||
default_setting == CONTENT_SETTING_BLOCK ||
@@ -124,7 +124,7 @@
HostContentSettingsMapFactory::GetForProfile(profile)
->SetContentSettingCustomScope(
pattern, ContentSettingsPattern::Wildcard(),
- CONTENT_SETTINGS_TYPE_NOTIFICATIONS,
+ ContentSettingsType::NOTIFICATIONS,
content_settings::ResourceIdentifier(), CONTENT_SETTING_DEFAULT);
}
}