diff options
author | msramek <msramek@chromium.org> | 2015-08-17 02:12:35 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-08-17 09:13:02 +0000 |
commit | c736b6bd3d9d49e43d09654a779913d048d3619d (patch) | |
tree | 46dbbbb72c0541d367de006c4f6496b73ed9da4f /components/content_settings | |
parent | 80d192f07aeba1a040163ad72a1596ce37999b7e (diff) | |
download | chromium_src-c736b6bd3d9d49e43d09654a779913d048d3619d.zip chromium_src-c736b6bd3d9d49e43d09654a779913d048d3619d.tar.gz chromium_src-c736b6bd3d9d49e43d09654a779913d048d3619d.tar.bz2 |
Clean up the mediastream migration pref.
We removed the mediastream->camera/mic migration code from content_settings::DefaultProvider, but didn't clean up the associated preference.
BUG=443799
Review URL: https://codereview.chromium.org/1255243004
Cr-Commit-Position: refs/heads/master@{#343651}
Diffstat (limited to 'components/content_settings')
3 files changed, 8 insertions, 12 deletions
diff --git a/components/content_settings/core/browser/content_settings_default_provider.cc b/components/content_settings/core/browser/content_settings_default_provider.cc index 8b6127c..e36cf7f 100644 --- a/components/content_settings/core/browser/content_settings_default_provider.cc +++ b/components/content_settings/core/browser/content_settings_default_provider.cc @@ -36,6 +36,8 @@ const char kObsoleteDefaultContentSettings[] = "profile.default_content_settings"; const char kObsoleteMigratedDefaultContentSettings[] = "profile.migrated_default_content_settings"; +const char kObsoleteMigratedDefaultMediaStreamSetting[] = + "profile.migrated_default_media_stream_content_settings"; ContentSetting GetDefaultValue(ContentSettingsType type) { if (type == CONTENT_SETTINGS_TYPE_PLUGINS) @@ -90,11 +92,6 @@ void DefaultProvider::RegisterProfilePrefs( PrefRegistrationFlagsForType(type)); } - // Whether the deprecated mediastream default setting has already been - // migrated into microphone and camera default settings. - registry->RegisterBooleanPref(prefs::kMigratedDefaultMediaStreamSetting, - false); - // Obsolete prefs ------------------------------------------------------- // The deprecated dictionary preference. @@ -109,6 +106,11 @@ void DefaultProvider::RegisterProfilePrefs( kObsoleteMigratedDefaultContentSettings, false, user_prefs::PrefRegistrySyncable::SYNCABLE_PREF); + + // Whether the deprecated mediastream default setting has already been + // migrated into microphone and camera default settings. + registry->RegisterBooleanPref(kObsoleteMigratedDefaultMediaStreamSetting, + false); } DefaultProvider::DefaultProvider(PrefService* prefs, bool incognito) @@ -363,6 +365,7 @@ void DefaultProvider::ForceDefaultsToBeExplicit(ValueMap* value_map) { void DefaultProvider::DiscardObsoletePreferences() { prefs_->ClearPref(kObsoleteDefaultContentSettings); prefs_->ClearPref(kObsoleteMigratedDefaultContentSettings); + prefs_->ClearPref(kObsoleteMigratedDefaultMediaStreamSetting); } } // namespace content_settings diff --git a/components/content_settings/core/common/pref_names.cc b/components/content_settings/core/common/pref_names.cc index 3b84e71..0c21850 100644 --- a/components/content_settings/core/common/pref_names.cc +++ b/components/content_settings/core/common/pref_names.cc @@ -18,11 +18,6 @@ const char kContentSettingsVersion[] = "profile.content_settings.pref_version"; const char kContentSettingsWindowLastTabIndex[] = "content_settings_window.last_tab_index"; -// Boolean indicating whether the media stream default setting had been -// migrated into two separate microphone and camera settings. -const char kMigratedDefaultMediaStreamSetting[] = - "profile.migrated_default_media_stream_content_settings"; - // Preferences that are exclusively used to store managed values for default // content settings. const char kManagedDefaultCookiesSetting[] = diff --git a/components/content_settings/core/common/pref_names.h b/components/content_settings/core/common/pref_names.h index 795d8b75..da2a851 100644 --- a/components/content_settings/core/common/pref_names.h +++ b/components/content_settings/core/common/pref_names.h @@ -17,8 +17,6 @@ extern const char kBlockThirdPartyCookies[]; extern const char kContentSettingsVersion[]; extern const char kContentSettingsWindowLastTabIndex[]; -extern const char kMigratedDefaultMediaStreamSetting[]; - extern const char kManagedDefaultCookiesSetting[]; extern const char kManagedDefaultImagesSetting[]; extern const char kManagedDefaultJavaScriptSetting[]; |