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

Unified Diff: xfa/fwl/cfwl_combobox.cpp

Issue 2571913002: Avoid the ptr.reset(new XXX()) anti-pattern (Closed)
Patch Set: rebase Created 4 years 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 | « xfa/fgas/layout/fgas_textbreak.cpp ('k') | xfa/fwl/cfwl_datetimepicker.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: xfa/fwl/cfwl_combobox.cpp
diff --git a/xfa/fwl/cfwl_combobox.cpp b/xfa/fwl/cfwl_combobox.cpp
index eb6bb632cda024fd214e7f1999a3eb6b854c2b28..7e5d1b8d747d7d0ae651cfdacebfb33e1cd1ca12 100644
--- a/xfa/fwl/cfwl_combobox.cpp
+++ b/xfa/fwl/cfwl_combobox.cpp
@@ -56,8 +56,8 @@ CFWL_ComboBox::CFWL_ComboBox(const CFWL_App* app)
pdfium::MakeUnique<CFWL_ComboList>(m_pOwnerApp, std::move(prop), this);
if ((m_pProperties->m_dwStyleExes & FWL_STYLEEXT_CMB_DropDown) && !m_pEdit) {
- m_pEdit.reset(new CFWL_ComboEdit(
- m_pOwnerApp, pdfium::MakeUnique<CFWL_WidgetProperties>(), this));
+ m_pEdit = pdfium::MakeUnique<CFWL_ComboEdit>(
+ m_pOwnerApp, pdfium::MakeUnique<CFWL_WidgetProperties>(), this);
m_pEdit->SetOuter(this);
}
if (m_pEdit)
« no previous file with comments | « xfa/fgas/layout/fgas_textbreak.cpp ('k') | xfa/fwl/cfwl_datetimepicker.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698