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_factory.h" | 5 #include "components/password_manager/content/browser/content_password_manager_d
river_factory.h" |
6 | 6 |
7 #include <utility> | 7 #include <utility> |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/memory/ptr_util.h" | 10 #include "base/memory/ptr_util.h" |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
44 web_contents, password_client, autofill_client)); | 44 web_contents, password_client, autofill_client)); |
45 const std::vector<content::RenderFrameHost*> frames = | 45 const std::vector<content::RenderFrameHost*> frames = |
46 web_contents->GetAllFrames(); | 46 web_contents->GetAllFrames(); |
47 for (content::RenderFrameHost* frame : frames) { | 47 for (content::RenderFrameHost* frame : frames) { |
48 if (frame->IsRenderFrameLive()) | 48 if (frame->IsRenderFrameLive()) |
49 new_factory->RenderFrameCreated(frame); | 49 new_factory->RenderFrameCreated(frame); |
50 } | 50 } |
51 | 51 |
52 web_contents->SetUserData( | 52 web_contents->SetUserData( |
53 kContentPasswordManagerDriverFactoryWebContentsUserDataKey, | 53 kContentPasswordManagerDriverFactoryWebContentsUserDataKey, |
54 new_factory.release()); | 54 std::move(new_factory)); |
55 } | 55 } |
56 | 56 |
57 ContentPasswordManagerDriverFactory::ContentPasswordManagerDriverFactory( | 57 ContentPasswordManagerDriverFactory::ContentPasswordManagerDriverFactory( |
58 content::WebContents* web_contents, | 58 content::WebContents* web_contents, |
59 PasswordManagerClient* password_client, | 59 PasswordManagerClient* password_client, |
60 autofill::AutofillClient* autofill_client) | 60 autofill::AutofillClient* autofill_client) |
61 : content::WebContentsObserver(web_contents), | 61 : content::WebContentsObserver(web_contents), |
62 password_client_(password_client), | 62 password_client_(password_client), |
63 autofill_client_(autofill_client) {} | 63 autofill_client_(autofill_client) {} |
64 | 64 |
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
154 ->second->DidNavigateFrame(navigation_handle); | 154 ->second->DidNavigateFrame(navigation_handle); |
155 } | 155 } |
156 | 156 |
157 void ContentPasswordManagerDriverFactory::RequestSendLoggingAvailability() { | 157 void ContentPasswordManagerDriverFactory::RequestSendLoggingAvailability() { |
158 for (const auto& key_val_iterator : frame_driver_map_) { | 158 for (const auto& key_val_iterator : frame_driver_map_) { |
159 key_val_iterator.second->SendLoggingAvailability(); | 159 key_val_iterator.second->SendLoggingAvailability(); |
160 } | 160 } |
161 } | 161 } |
162 | 162 |
163 } // namespace password_manager | 163 } // namespace password_manager |
OLD | NEW |