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

Unified Diff: xfa/fxfa/include/xfa_ffpageview.h

Issue 1976123003: Remove { delete this; } anti-pattern from IXFA_WidgetIterator (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Restore page Release(). Created 4 years, 7 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 | « xfa/fxfa/include/xfa_ffdocview.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: xfa/fxfa/include/xfa_ffpageview.h
diff --git a/xfa/fxfa/include/xfa_ffpageview.h b/xfa/fxfa/include/xfa_ffpageview.h
index 75e418b25b04e3f356a93790fbb0505df886ba8d..79b0afb602df8b78375cae030e1b0ade265fb6ac 100644
--- a/xfa/fxfa/include/xfa_ffpageview.h
+++ b/xfa/fxfa/include/xfa_ffpageview.h
@@ -36,12 +36,11 @@ class CXFA_FFPageView : public CXFA_ContainerLayoutItem {
typedef CXFA_NodeIteratorTemplate<CXFA_LayoutItem,
CXFA_TraverseStrategy_LayoutItem>
CXFA_LayoutItemIterator;
+
class CXFA_FFPageWidgetIterator : public IXFA_WidgetIterator {
public:
CXFA_FFPageWidgetIterator(CXFA_FFPageView* pPageView, uint32_t dwFilter);
- virtual ~CXFA_FFPageWidgetIterator();
-
- void Release() override { delete this; }
+ ~CXFA_FFPageWidgetIterator() override;
void Reset() override;
CXFA_FFWidget* MoveToFirst() override;
@@ -73,9 +72,7 @@ class CXFA_FFTabOrderPageWidgetIterator : public IXFA_WidgetIterator {
public:
CXFA_FFTabOrderPageWidgetIterator(CXFA_FFPageView* pPageView,
uint32_t dwFilter);
- virtual ~CXFA_FFTabOrderPageWidgetIterator();
-
- void Release() override;
+ ~CXFA_FFTabOrderPageWidgetIterator() override;
void Reset() override;
CXFA_FFWidget* MoveToFirst() override;
« no previous file with comments | « xfa/fxfa/include/xfa_ffdocview.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698