summaryrefslogtreecommitdiffstats
path: root/chrome/browser/content_setting_bubble_model_unittest.cc
diff options
context:
space:
mode:
authorbauerb@chromium.org <bauerb@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-08-12 16:14:22 +0000
committerbauerb@chromium.org <bauerb@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-08-12 16:14:22 +0000
commit6b3db4350e3cb5b7d5ef9ff5995f5dcfe9bac6e9 (patch)
treebde9dde95d828715441bb818cf78397846ef32c7 /chrome/browser/content_setting_bubble_model_unittest.cc
parent3c5ce41e6cb80f816e7d398594d77e2c6b03a22a (diff)
downloadchromium_src-6b3db4350e3cb5b7d5ef9ff5995f5dcfe9bac6e9.zip
chromium_src-6b3db4350e3cb5b7d5ef9ff5995f5dcfe9bac6e9.tar.gz
chromium_src-6b3db4350e3cb5b7d5ef9ff5995f5dcfe9bac6e9.tar.bz2
Revert 55888: Allow per-plugin content settings.
Run with --enable-resource-content-settings and --enable-click-to-play to enable. TabSpecificContentSettings now keeps track of which resources were blocked. The content setting bubble displays those resource, and selecting the "allow radio buttons adds exceptions for these resources. The infobar for non-sandboxed plug-ins now also shows a button to always allow the blocked plug-in on that site. Screenshot of the plugin bubble: http://imgur.com/6npqv.png Because we need to change the title and radio button labels depending on whether we track specific plug-ins, we copy them from the ContentSettingBubbleModel. XIB changes: Add a text field for the blocked plug-ins to ContentBlockedPlugins.xib, hooked up to the |blockedResourcesField_| outlet. BUG=39252,38432 TEST=manual Review URL: http://codereview.chromium.org/2873104 TBR: bauerb@chromium.org git-svn-id: svn://svn.chromium.org/chrome/trunk/src@55891 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/content_setting_bubble_model_unittest.cc')
-rw-r--r--chrome/browser/content_setting_bubble_model_unittest.cc9
1 files changed, 3 insertions, 6 deletions
diff --git a/chrome/browser/content_setting_bubble_model_unittest.cc b/chrome/browser/content_setting_bubble_model_unittest.cc
index 3f443cf..7a77fb9 100644
--- a/chrome/browser/content_setting_bubble_model_unittest.cc
+++ b/chrome/browser/content_setting_bubble_model_unittest.cc
@@ -47,8 +47,7 @@ class ContentSettingBubbleModelTest : public RenderViewHostTestHarness {
TEST_F(ContentSettingBubbleModelTest, ImageRadios) {
TabSpecificContentSettings* content_settings =
contents()->GetTabSpecificContentSettings();
- content_settings->OnContentBlocked(CONTENT_SETTINGS_TYPE_IMAGES,
- std::string());
+ content_settings->OnContentBlocked(CONTENT_SETTINGS_TYPE_IMAGES);
scoped_ptr<ContentSettingBubbleModel> content_setting_bubble_model(
ContentSettingBubbleModel::CreateContentSettingBubbleModel(
@@ -66,8 +65,7 @@ TEST_F(ContentSettingBubbleModelTest, ImageRadios) {
TEST_F(ContentSettingBubbleModelTest, Cookies) {
TabSpecificContentSettings* content_settings =
contents()->GetTabSpecificContentSettings();
- content_settings->OnContentBlocked(CONTENT_SETTINGS_TYPE_COOKIES,
- std::string());
+ content_settings->OnContentBlocked(CONTENT_SETTINGS_TYPE_COOKIES);
scoped_ptr<ContentSettingBubbleModel> content_setting_bubble_model(
ContentSettingBubbleModel::CreateContentSettingBubbleModel(
@@ -84,8 +82,7 @@ TEST_F(ContentSettingBubbleModelTest, Cookies) {
TEST_F(ContentSettingBubbleModelTest, Plugins) {
TabSpecificContentSettings* content_settings =
contents()->GetTabSpecificContentSettings();
- content_settings->OnContentBlocked(CONTENT_SETTINGS_TYPE_PLUGINS,
- std::string());
+ content_settings->OnContentBlocked(CONTENT_SETTINGS_TYPE_PLUGINS);
scoped_ptr<ContentSettingBubbleModel> content_setting_bubble_model(
ContentSettingBubbleModel::CreateContentSettingBubbleModel(