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

Unified Diff: chrome/browser/autofill/autofill_manager.cc

Issue 11345008: Remove content::NotificationObserver dependency from most Prefs code. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Merge to head for commit 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
« no previous file with comments | « chrome/browser/autofill/autofill_manager.h ('k') | chrome/browser/background/background_mode_manager.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/autofill/autofill_manager.cc
diff --git a/chrome/browser/autofill/autofill_manager.cc b/chrome/browser/autofill/autofill_manager.cc
index f9dfd82a7e3b4be008cfffe9820981709c137158..132d4ce85a0aa4cf93abfbb2df48e736f6a7e3dd 100644
--- a/chrome/browser/autofill/autofill_manager.cc
+++ b/chrome/browser/autofill/autofill_manager.cc
@@ -290,14 +290,10 @@ void AutofillManager::RenderViewCreated(content::RenderViewHost* host) {
UpdatePasswordGenerationState(host, true);
}
-void AutofillManager::Observe(
- int type,
- const content::NotificationSource& source,
- const content::NotificationDetails& details) {
+void AutofillManager::OnPreferenceChanged(PrefServiceBase* service,
+ const std::string& pref_name) {
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
- DCHECK_EQ(chrome::NOTIFICATION_PREF_CHANGED, type);
- std::string* pref = content::Details<std::string>(details).ptr();
- DCHECK(prefs::kPasswordGenerationEnabled == *pref);
+ DCHECK(prefs::kPasswordGenerationEnabled == pref_name);
UpdatePasswordGenerationState(web_contents()->GetRenderViewHost(), false);
}
« no previous file with comments | « chrome/browser/autofill/autofill_manager.h ('k') | chrome/browser/background/background_mode_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698