Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3053)

Unified Diff: chrome/browser/ui/webui/options/content_settings_handler.cc

Issue 11421029: Remove PrefObserver usages, batch 13. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix - rebase Created 8 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/webui/options/content_settings_handler.cc
diff --git a/chrome/browser/ui/webui/options/content_settings_handler.cc b/chrome/browser/ui/webui/options/content_settings_handler.cc
index f1537732feee71232d500446706f27e4b88aa58a..5e217c3e29a3c8725b5428ee61c53c0877b1fcf4 100644
--- a/chrome/browser/ui/webui/options/content_settings_handler.cc
+++ b/chrome/browser/ui/webui/options/content_settings_handler.cc
@@ -488,7 +488,11 @@ void ContentSettingsHandler::InitializeHandler() {
PrefService* prefs = profile->GetPrefs();
pref_change_registrar_.Init(prefs);
- pref_change_registrar_.Add(prefs::kPepperFlashSettingsEnabled, this);
+ pref_change_registrar_.Add(
+ prefs::kPepperFlashSettingsEnabled,
+ base::Bind(&ContentSettingsHandler::RefreshFlashSettingsCache,
+ base::Unretained(this),
+ false));
flash_settings_manager_.reset(new PepperFlashSettingsManager(this, profile));
}
@@ -556,12 +560,6 @@ void ContentSettingsHandler::Observe(
}
}
-void ContentSettingsHandler::OnPreferenceChanged(PrefServiceBase* service,
- const std::string& pref_name) {
- DCHECK_EQ(pref_name, std::string(prefs::kPepperFlashSettingsEnabled));
- RefreshFlashSettingsCache(false);
-}
-
void ContentSettingsHandler::OnGetPermissionSettingsCompleted(
uint32 request_id,
bool success,
« no previous file with comments | « chrome/browser/ui/webui/options/content_settings_handler.h ('k') | chrome/browser/ui/webui/options/font_settings_handler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698