From f74ad998d2e8d2636fb25e94823946a3b151e34e Mon Sep 17 00:00:00 2001 From: tsepez Date: Wed, 11 May 2016 10:26:05 -0700 Subject: Replace some calls to Release() with direct delete, part 1. Searching for the anti-pattern: void Release() { delete this; } We must be explicit on the ownership model. Add unique_ptrs as a result. Review-Url: https://codereview.chromium.org/1960673003 --- xfa/fde/fde_gedevice.h | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'xfa/fde/fde_gedevice.h') diff --git a/xfa/fde/fde_gedevice.h b/xfa/fde/fde_gedevice.h index 3d14a0f8af..f69e4d106c 100644 --- a/xfa/fde/fde_gedevice.h +++ b/xfa/fde/fde_gedevice.h @@ -21,9 +21,7 @@ class IFX_Font; class CFDE_RenderDevice : public CFX_Target { public: CFDE_RenderDevice(CFX_RenderDevice* pDevice, FX_BOOL bOwnerDevice); - ~CFDE_RenderDevice(); - - void Release() { delete this; } + ~CFDE_RenderDevice() override; int32_t GetWidth() const; int32_t GetHeight() const; -- cgit v1.2.3