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

Unified Diff: components/password_manager/content/browser/content_password_manager_driver_factory.cc

Issue 1852093002: components/password_manager: scoped_ptr -> unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase and revert an accidental .proto change Created 4 years, 9 months 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: components/password_manager/content/browser/content_password_manager_driver_factory.cc
diff --git a/components/password_manager/content/browser/content_password_manager_driver_factory.cc b/components/password_manager/content/browser/content_password_manager_driver_factory.cc
index 1432e1486c8ca3700e97672df9c4fb657b4d3758..be8b22a5668d9ae8234e4e0813a5fce38c7f236d 100644
--- a/components/password_manager/content/browser/content_password_manager_driver_factory.cc
+++ b/components/password_manager/content/browser/content_password_manager_driver_factory.cc
@@ -6,6 +6,7 @@
#include <utility>
+#include "base/memory/ptr_util.h"
#include "base/stl_util.h"
#include "components/autofill/content/browser/content_autofill_driver.h"
#include "components/autofill/content/browser/content_autofill_driver_factory.h"
@@ -56,7 +57,7 @@ ContentPasswordManagerDriverFactory::ContentPasswordManagerDriverFactory(
content::RenderFrameHost* main_frame = web_contents->GetMainFrame();
if (main_frame->IsRenderFrameLive()) {
frame_driver_map_[main_frame] =
- make_scoped_ptr(new ContentPasswordManagerDriver(
+ base::WrapUnique(new ContentPasswordManagerDriver(
main_frame, password_client_, autofill_client_));
}
}
@@ -86,7 +87,7 @@ void ContentPasswordManagerDriverFactory::RenderFrameCreated(
// This is called twice for the main frame.
if (insertion_result.second) { // This was the first time.
insertion_result.first->second =
- make_scoped_ptr(new ContentPasswordManagerDriver(
+ base::WrapUnique(new ContentPasswordManagerDriver(
render_frame_host, password_client_, autofill_client_));
insertion_result.first->second->SendLoggingAvailability();
}
@@ -114,7 +115,7 @@ void ContentPasswordManagerDriverFactory::DidNavigateAnyFrame(
void ContentPasswordManagerDriverFactory::TestingSetDriverForFrame(
content::RenderFrameHost* render_frame_host,
- scoped_ptr<ContentPasswordManagerDriver> driver) {
+ std::unique_ptr<ContentPasswordManagerDriver> driver) {
frame_driver_map_[render_frame_host] = std::move(driver);
}

Powered by Google App Engine
This is Rietveld 408576698