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

Unified Diff: xfa/src/fwl/src/basewidget/fwl_barcodeimp.cpp

Issue 1458173002: Fix CFWL_WidgetImpDelegate hierarchy. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@xfa
Patch Set: Created 5 years, 1 month 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 | « no previous file | xfa/src/fwl/src/basewidget/fwl_caretimp.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: xfa/src/fwl/src/basewidget/fwl_barcodeimp.cpp
diff --git a/xfa/src/fwl/src/basewidget/fwl_barcodeimp.cpp b/xfa/src/fwl/src/basewidget/fwl_barcodeimp.cpp
index c65a35064561b00fb1a007ccc0d3c5ee334f5eaa..5544162380ba6e4f2c2386a055efcae55c648657 100644
--- a/xfa/src/fwl/src/basewidget/fwl_barcodeimp.cpp
+++ b/xfa/src/fwl/src/basewidget/fwl_barcodeimp.cpp
@@ -51,17 +51,15 @@ FX_DWORD CFWL_BarcodeImp::GetClassID() const {
}
FWL_ERR CFWL_BarcodeImp::Initialize() {
if (!m_pDelegate) {
- m_pDelegate = (IFWL_WidgetDelegate*)new CFWL_BarcodeImpDelegate(this);
Lei Zhang 2015/11/20 03:11:43 Ya, umm, wow.
+ m_pDelegate = new CFWL_BarcodeImpDelegate(this);
}
_FWL_ERR_CHECK_RETURN_VALUE_IF_FAIL(CFWL_EditImp::Initialize(),
FWL_ERR_Indefinite);
return FWL_ERR_Succeeded;
}
FWL_ERR CFWL_BarcodeImp::Finalize() {
- if (m_pDelegate) {
- delete (CFWL_BarcodeImpDelegate*)m_pDelegate;
- m_pDelegate = NULL;
- }
+ delete m_pDelegate;
+ m_pDelegate = nullptr;
ReleaseBarcodeEngine();
return CFWL_EditImp::Finalize();
}
« no previous file with comments | « no previous file | xfa/src/fwl/src/basewidget/fwl_caretimp.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698