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

Unified Diff: chrome/browser/autofill/personal_data_manager.h

Issue 2975003: Makes the auto fill dialogs match the mocks. (Closed)
Patch Set: Moves function declarations out of autofill_dialog.h Created 10 years, 5 months 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/credit_card.cc ('k') | chrome/browser/autofill/personal_data_manager.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/autofill/personal_data_manager.h
diff --git a/chrome/browser/autofill/personal_data_manager.h b/chrome/browser/autofill/personal_data_manager.h
index 8c5a04ef329b9f23fe8c8516734778ac421b801c..50455ec7bb7948df90f38b19f62559046ef94556 100644
--- a/chrome/browser/autofill/personal_data_manager.h
+++ b/chrome/browser/autofill/personal_data_manager.h
@@ -8,6 +8,7 @@
#include <set>
#include <vector>
+#include "base/observer_list.h"
#include "base/ref_counted.h"
#include "base/scoped_ptr.h"
#include "base/scoped_vector.h"
@@ -36,8 +37,13 @@ class PersonalDataManager
class Observer {
public:
// Notifies the observer that the PersonalDataManager has finished loading.
+ // TODO: OnPersonalDataLoaded should be nuked in favor of only
+ // OnPersonalDataChanged.
virtual void OnPersonalDataLoaded() = 0;
+ // Notifies the observer that the PersonalDataManager changed in some way.
+ virtual void OnPersonalDataChanged() {}
+
protected:
virtual ~Observer() {}
};
@@ -240,8 +246,8 @@ class PersonalDataManager
WebDataService::Handle pending_profiles_query_;
WebDataService::Handle pending_creditcards_query_;
- // The observers. This can be empty.
- std::vector<PersonalDataManager::Observer*> observers_;
+ // The observers.
+ ObserverList<Observer> observers_;
DISALLOW_COPY_AND_ASSIGN(PersonalDataManager);
};
« no previous file with comments | « chrome/browser/autofill/credit_card.cc ('k') | chrome/browser/autofill/personal_data_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698