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

Unified Diff: ui/web_dialogs/web_dialog_ui.cc

Issue 2842833003: Update SupportsUserData uses with unique_ptr. (Closed)
Patch Set: rebase Created 3 years, 8 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
« no previous file with comments | « storage/browser/blob/blob_url_request_job_factory.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/web_dialogs/web_dialog_ui.cc
diff --git a/ui/web_dialogs/web_dialog_ui.cc b/ui/web_dialogs/web_dialog_ui.cc
index c4767024920ae221c70993243da3f4735ed395dd..484d2803ff8202f9c304e9385237089f7f10b43b 100644
--- a/ui/web_dialogs/web_dialog_ui.cc
+++ b/ui/web_dialogs/web_dialog_ui.cc
@@ -7,6 +7,7 @@
#include "base/bind.h"
#include "base/bind_helpers.h"
#include "base/lazy_instance.h"
+#include "base/memory/ptr_util.h"
#include "base/values.h"
#include "content/public/browser/render_frame_host.h"
#include "content/public/browser/render_view_host.h"
@@ -60,8 +61,9 @@ void WebDialogUI::CloseDialog(const base::ListValue* args) {
// static
void WebDialogUI::SetDelegate(content::WebContents* web_contents,
WebDialogDelegate* delegate) {
- web_contents->SetUserData(&kWebDialogDelegateUserDataKey,
- new WebDialogDelegateUserData(delegate));
+ web_contents->SetUserData(
+ &kWebDialogDelegateUserDataKey,
+ base::MakeUnique<WebDialogDelegateUserData>(delegate));
}
////////////////////////////////////////////////////////////////////////////////
« no previous file with comments | « storage/browser/blob/blob_url_request_job_factory.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698