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

Unified Diff: chrome/browser/extensions/api/passwords_private/passwords_private_delegate.h

Issue 2468763002: MD Settings: fix chrome.passwordsPrivate empty list bug (Closed)
Patch Set: fix ups Created 4 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/extensions/api/passwords_private/passwords_private_delegate.h
diff --git a/chrome/browser/extensions/api/passwords_private/passwords_private_delegate.h b/chrome/browser/extensions/api/passwords_private/passwords_private_delegate.h
index 7d5d230abffe0bf1e4bcb58dfab692b1a9c8815b..a16477bf2985b9a6db8c10cda20722fbad700e78 100644
--- a/chrome/browser/extensions/api/passwords_private/passwords_private_delegate.h
+++ b/chrome/browser/extensions/api/passwords_private/passwords_private_delegate.h
@@ -42,15 +42,18 @@ class PasswordsPrivateDelegate : public KeyedService {
virtual void SendSavedPasswordsList() = 0;
// Gets the saved passwords list.
- virtual const std::vector<api::passwords_private::PasswordUiEntry>*
- GetSavedPasswordsList() const = 0;
+ using UiEntries = std::vector<api::passwords_private::PasswordUiEntry>;
+ using UiEntriesCallback = base::Callback<void(const UiEntries*)>;
Devlin 2016/11/01 00:09:57 Why pass this as a const UiEntries* instead of con
Dan Beam 2016/11/01 21:08:25 Done.
+ virtual void GetSavedPasswordsList(const UiEntriesCallback& callback) = 0;
// Sends the password exceptions list to the event router.
virtual void SendPasswordExceptionsList() = 0;
// Gets the password exceptions list.
- virtual const std::vector<api::passwords_private::ExceptionPair>*
- GetPasswordExceptionsList() const = 0;
+ using ExceptionPairs = std::vector<api::passwords_private::ExceptionPair>;
+ using ExceptionPairsCallback = base::Callback<void(const ExceptionPairs*)>;
+ virtual void GetPasswordExceptionsList(
+ const ExceptionPairsCallback& callback) = 0;
// Removes the saved password entry corresponding to |origin_url| and
// |username|.

Powered by Google App Engine
This is Rietveld 408576698