Index: components/password_manager/core/browser/credential_manager_pending_request_task.h |
diff --git a/components/password_manager/core/browser/credential_manager_pending_request_task.h b/components/password_manager/core/browser/credential_manager_pending_request_task.h |
index 1cafaf1bd438a60f51e876255797f23b29ff01e9..61211b2194a8a51a8e8121f5b5a212111f28b389 100644 |
--- a/components/password_manager/core/browser/credential_manager_pending_request_task.h |
+++ b/components/password_manager/core/browser/credential_manager_pending_request_task.h |
@@ -24,9 +24,6 @@ |
struct CredentialInfo; |
class PasswordManagerClient; |
-typedef base::Callback<void(const CredentialInfo& credential)> |
- SendCredentialCallback; |
- |
// Sends credentials retrieved from the PasswordStore to CredentialManager API |
// clients and retrieves embedder-dependent information. |
class CredentialManagerPendingRequestTaskDelegate { |
@@ -44,13 +41,11 @@ |
virtual PasswordManagerClient* client() const = 0; |
// Sends a credential to JavaScript. |
- virtual void SendCredential(const SendCredentialCallback& send_callback, |
- const CredentialInfo& credential) = 0; |
+ virtual void SendCredential(int id, const CredentialInfo& credential) = 0; |
// Updates |skip_zero_click| for |form| in the PasswordStore if required. |
// Sends a credential to JavaScript. |
- virtual void SendPasswordForm(const SendCredentialCallback& send_callback, |
- const autofill::PasswordForm* form) = 0; |
+ virtual void SendPasswordForm(int id, const autofill::PasswordForm* form) = 0; |
}; |
// Retrieves credentials from the PasswordStore. |
@@ -58,7 +53,7 @@ |
public: |
CredentialManagerPendingRequestTask( |
CredentialManagerPendingRequestTaskDelegate* delegate, |
- const SendCredentialCallback& callback, |
+ int request_id, |
bool request_zero_click_only, |
const GURL& request_origin, |
bool include_passwords, |
@@ -66,7 +61,7 @@ |
const std::vector<std::string>& affiliated_realms); |
~CredentialManagerPendingRequestTask() override; |
- SendCredentialCallback send_callback() const { return send_callback_; } |
+ int id() const { return id_; } |
const GURL& origin() const { return origin_; } |
// PasswordStoreConsumer implementation. |
@@ -75,7 +70,7 @@ |
private: |
CredentialManagerPendingRequestTaskDelegate* delegate_; // Weak; |
- SendCredentialCallback send_callback_; |
+ const int id_; |
const bool zero_click_only_; |
const GURL origin_; |
const bool include_passwords_; |