| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 #include "components/password_manager/content/browser/content_password_manager_d
river.h" | 5 #include "components/password_manager/content/browser/content_password_manager_d
river.h" |
| 6 | 6 |
| 7 #include "components/autofill/content/browser/content_autofill_driver.h" | 7 #include "components/autofill/content/browser/content_autofill_driver.h" |
| 8 #include "components/autofill/core/common/form_data.h" | 8 #include "components/autofill/core/common/form_data.h" |
| 9 #include "components/autofill/core/common/password_form.h" | 9 #include "components/autofill/core/common/password_form.h" |
| 10 #include "components/password_manager/content/browser/bad_message.h" | 10 #include "components/password_manager/content/browser/bad_message.h" |
| (...skipping 291 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 302 autofill::ContentAutofillDriver::GetForRenderFrameHost( | 302 autofill::ContentAutofillDriver::GetForRenderFrameHost( |
| 303 render_frame_host_); | 303 render_frame_host_); |
| 304 DCHECK(autofill_driver); | 304 DCHECK(autofill_driver); |
| 305 return autofill_driver->GetAutofillAgent(); | 305 return autofill_driver->GetAutofillAgent(); |
| 306 } | 306 } |
| 307 | 307 |
| 308 const autofill::mojom::PasswordAutofillAgentPtr& | 308 const autofill::mojom::PasswordAutofillAgentPtr& |
| 309 ContentPasswordManagerDriver::GetPasswordAutofillAgent() { | 309 ContentPasswordManagerDriver::GetPasswordAutofillAgent() { |
| 310 if (!password_autofill_agent_) { | 310 if (!password_autofill_agent_) { |
| 311 autofill::mojom::PasswordAutofillAgentRequest request = | 311 autofill::mojom::PasswordAutofillAgentRequest request = |
| 312 mojo::GetProxy(&password_autofill_agent_); | 312 mojo::MakeRequest(&password_autofill_agent_); |
| 313 // Some test codes may have no initialized remote interfaces. | 313 // Some test codes may have no initialized remote interfaces. |
| 314 if (render_frame_host_->GetRemoteInterfaces()) { | 314 if (render_frame_host_->GetRemoteInterfaces()) { |
| 315 render_frame_host_->GetRemoteInterfaces()->GetInterface( | 315 render_frame_host_->GetRemoteInterfaces()->GetInterface( |
| 316 std::move(request)); | 316 std::move(request)); |
| 317 } | 317 } |
| 318 } | 318 } |
| 319 | 319 |
| 320 return password_autofill_agent_; | 320 return password_autofill_agent_; |
| 321 } | 321 } |
| 322 | 322 |
| 323 const autofill::mojom::PasswordGenerationAgentPtr& | 323 const autofill::mojom::PasswordGenerationAgentPtr& |
| 324 ContentPasswordManagerDriver::GetPasswordGenerationAgent() { | 324 ContentPasswordManagerDriver::GetPasswordGenerationAgent() { |
| 325 if (!password_gen_agent_) { | 325 if (!password_gen_agent_) { |
| 326 render_frame_host_->GetRemoteInterfaces()->GetInterface( | 326 render_frame_host_->GetRemoteInterfaces()->GetInterface( |
| 327 mojo::GetProxy(&password_gen_agent_)); | 327 mojo::MakeRequest(&password_gen_agent_)); |
| 328 } | 328 } |
| 329 | 329 |
| 330 return password_gen_agent_; | 330 return password_gen_agent_; |
| 331 } | 331 } |
| 332 | 332 |
| 333 } // namespace password_manager | 333 } // namespace password_manager |
| OLD | NEW |