Skip to content

Commit

Permalink
Merge pull request #700 from brave/mpilgrim_flash_2
Browse files Browse the repository at this point in the history
Move Flash default to ContentSettingsRegistry
  • Loading branch information
bbondy committed Oct 22, 2018
1 parent 42f8832 commit 549685e
Show file tree
Hide file tree
Showing 7 changed files with 16 additions and 145 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,22 @@ void ContentSettingsRegistry::BraveInit() {
ContentSettingsInfo::INHERIT_IN_INCOGNITO,
ContentSettingsInfo::PERSISTENT);

// Change plugins default to CONTENT_SETTING_BLOCK
content_settings_info_.erase(CONTENT_SETTINGS_TYPE_PLUGINS);
website_settings_registry_->UnRegister(CONTENT_SETTINGS_TYPE_PLUGINS);
Register(
CONTENT_SETTINGS_TYPE_PLUGINS, "plugins",
CONTENT_SETTING_BLOCK, WebsiteSettingsInfo::SYNCABLE,
WhitelistedSchemes(kChromeUIScheme, kChromeDevToolsScheme),
ValidSettings(CONTENT_SETTING_ALLOW, CONTENT_SETTING_BLOCK,
CONTENT_SETTING_ASK,
CONTENT_SETTING_DETECT_IMPORTANT_CONTENT),
WebsiteSettingsInfo::SINGLE_ORIGIN_WITH_EMBEDDED_EXCEPTIONS_SCOPE,
WebsiteSettingsRegistry::DESKTOP,
ContentSettingsInfo::INHERIT_IF_LESS_PERMISSIVE,
base::FeatureList::IsEnabled(features::kEnableEphemeralFlashPermission)
? ContentSettingsInfo::EPHEMERAL
: ContentSettingsInfo::PERSISTENT);
}

} // namespace content_settings
2 changes: 0 additions & 2 deletions components/content_settings/core/browser/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@ source_set("browser") {
"brave_content_settings_pref_provider.h",
"brave_cookie_settings.cc",
"brave_cookie_settings.h",
"brave_host_content_settings_map.cc",
"brave_host_content_settings_map.h",
]

deps = [
Expand Down

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

1 change: 0 additions & 1 deletion test/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,6 @@ test("brave_unit_tests") {
"//brave/common/tor/tor_test_constants.h",
"//brave/components/brave_shields/browser/ad_block_regional_service_unittest.cc",
"//brave/components/brave_webtorrent/browser/net/brave_torrent_redirect_network_delegate_helper_unittest.cc",
"//brave/components/content_settings/core/browser/brave_host_content_settings_map_unittest.cc",
"//chrome/common/importer/mock_importer_bridge.cc",
"//chrome/common/importer/mock_importer_bridge.h",
"../browser/importer/chrome_profile_lock_unittest.cc",
Expand Down

0 comments on commit 549685e

Please sign in to comment.