diff options
author | cmp@chromium.org <cmp@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-11-10 01:46:50 +0000 |
---|---|---|
committer | cmp@chromium.org <cmp@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-11-10 01:46:50 +0000 |
commit | bfc2b4cbaa865df05976d73b989d321277b757aa (patch) | |
tree | a1f39f532ac30a15954cdfc56b5c980b2c268884 /chrome/common/content_settings.cc | |
parent | 063b841e1b7462f9af20d8a5e1613c0effe97a72 (diff) | |
download | chromium_src-bfc2b4cbaa865df05976d73b989d321277b757aa.zip chromium_src-bfc2b4cbaa865df05976d73b989d321277b757aa.tar.gz chromium_src-bfc2b4cbaa865df05976d73b989d321277b757aa.tar.bz2 |
Revert 109228 - ContentSettingsObserver (+ related classes) cleanup.
<cmp> This CL needs to be reverted before we revert 109213, which we
speculate caused some performance regressions.
Per-page content settings and default content settings are no longer needed,
since the renderer stores the content setting rules for images and scripts.
BUG=102662
TEST=NONE
Review URL: http://codereview.chromium.org/8498007
TBR=marja@chromium.org
Review URL: http://codereview.chromium.org/8497062
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@109360 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/common/content_settings.cc')
-rw-r--r-- | chrome/common/content_settings.cc | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/chrome/common/content_settings.cc b/chrome/common/content_settings.cc index 8b28f4b..cd30d6c 100644 --- a/chrome/common/content_settings.cc +++ b/chrome/common/content_settings.cc @@ -10,6 +10,16 @@ ContentSetting IntToContentSetting(int content_setting) { CONTENT_SETTING_DEFAULT : static_cast<ContentSetting>(content_setting); } +ContentSettings::ContentSettings() { + for (int i = 0; i < CONTENT_SETTINGS_NUM_TYPES; ++i) + settings[i] = CONTENT_SETTING_DEFAULT; +} + +ContentSettings::ContentSettings(ContentSetting default_setting) { + for (int i = 0; i < CONTENT_SETTINGS_NUM_TYPES; ++i) + settings[i] = default_setting; +} + ContentSettingPatternSource::ContentSettingPatternSource( const ContentSettingsPattern& primary_pattern, const ContentSettingsPattern& secondary_pattern, |