| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #import "ios/chrome/browser/passwords/ios_chrome_password_manager_client.h" | 5 #import "ios/chrome/browser/passwords/ios_chrome_password_manager_client.h" |
| 6 | 6 |
| 7 #include <memory> | 7 #include <memory> |
| 8 #include <utility> | 8 #include <utility> |
| 9 | 9 |
| 10 #include "components/autofill/core/common/password_form.h" | 10 #include "components/autofill/core/common/password_form.h" |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 47 this, | 47 this, |
| 48 base::Bind(&GetSyncService, delegate_.browserState), | 48 base::Bind(&GetSyncService, delegate_.browserState), |
| 49 base::Bind(&GetSigninManager, delegate_.browserState)) { | 49 base::Bind(&GetSigninManager, delegate_.browserState)) { |
| 50 saving_passwords_enabled_.Init( | 50 saving_passwords_enabled_.Init( |
| 51 password_manager::prefs::kPasswordManagerSavingEnabled, GetPrefs()); | 51 password_manager::prefs::kPasswordManagerSavingEnabled, GetPrefs()); |
| 52 } | 52 } |
| 53 | 53 |
| 54 IOSChromePasswordManagerClient::~IOSChromePasswordManagerClient() = default; | 54 IOSChromePasswordManagerClient::~IOSChromePasswordManagerClient() = default; |
| 55 | 55 |
| 56 PasswordSyncState IOSChromePasswordManagerClient::GetPasswordSyncState() const { | 56 PasswordSyncState IOSChromePasswordManagerClient::GetPasswordSyncState() const { |
| 57 ProfileSyncService* sync_service = | 57 browser_sync::ProfileSyncService* sync_service = |
| 58 IOSChromeProfileSyncServiceFactory::GetForBrowserState( | 58 IOSChromeProfileSyncServiceFactory::GetForBrowserState( |
| 59 delegate_.browserState); | 59 delegate_.browserState); |
| 60 return password_manager_util::GetPasswordSyncState(sync_service); | 60 return password_manager_util::GetPasswordSyncState(sync_service); |
| 61 } | 61 } |
| 62 | 62 |
| 63 bool IOSChromePasswordManagerClient::PromptUserToChooseCredentials( | 63 bool IOSChromePasswordManagerClient::PromptUserToChooseCredentials( |
| 64 ScopedVector<autofill::PasswordForm> local_forms, | 64 ScopedVector<autofill::PasswordForm> local_forms, |
| 65 ScopedVector<autofill::PasswordForm> federated_forms, | 65 ScopedVector<autofill::PasswordForm> federated_forms, |
| 66 const GURL& origin, | 66 const GURL& origin, |
| 67 const CredentialsCallback& callback) { | 67 const CredentialsCallback& callback) { |
| (...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 132 } | 132 } |
| 133 | 133 |
| 134 const GURL& IOSChromePasswordManagerClient::GetLastCommittedEntryURL() const { | 134 const GURL& IOSChromePasswordManagerClient::GetLastCommittedEntryURL() const { |
| 135 return delegate_.lastCommittedURL; | 135 return delegate_.lastCommittedURL; |
| 136 } | 136 } |
| 137 | 137 |
| 138 const password_manager::CredentialsFilter* | 138 const password_manager::CredentialsFilter* |
| 139 IOSChromePasswordManagerClient::GetStoreResultFilter() const { | 139 IOSChromePasswordManagerClient::GetStoreResultFilter() const { |
| 140 return &credentials_filter_; | 140 return &credentials_filter_; |
| 141 } | 141 } |
| OLD | NEW |