summaryrefslogtreecommitdiff
path: root/core/src/fxcodec
diff options
context:
space:
mode:
authorTom Sepez <tsepez@chromium.org>2015-06-18 12:47:11 -0700
committerTom Sepez <tsepez@chromium.org>2015-06-18 12:47:11 -0700
commit2c28619de8051661c7f66f2192c6fb9ef14ee905 (patch)
tree4bd15bf0bb72e4127403548bf2f40230bbdd352b /core/src/fxcodec
parent0c1bd7c6ad378ea97a2f54cb0c4761716f6d1057 (diff)
downloadpdfium-2c28619de8051661c7f66f2192c6fb9ef14ee905.tar.xz
Replace some Release() calls with virtual destructors.
Required fixing xfa-specific code. Original Review URL: https://codereview.chromium.org/1192013002. R=thestig@chromium.org Review URL: https://codereview.chromium.org/1176413004.
Diffstat (limited to 'core/src/fxcodec')
-rw-r--r--core/src/fxcodec/codec/fx_codec.cpp51
1 files changed, 12 insertions, 39 deletions
diff --git a/core/src/fxcodec/codec/fx_codec.cpp b/core/src/fxcodec/codec/fx_codec.cpp
index 319e66e69b..96366fae2b 100644
--- a/core/src/fxcodec/codec/fx_codec.cpp
+++ b/core/src/fxcodec/codec/fx_codec.cpp
@@ -6,38 +6,19 @@
#include "../../../include/fxcodec/fx_codec.h"
#include "codec_int.h"
+
CCodec_ModuleMgr::CCodec_ModuleMgr()
-{
- m_pBasicModule = new CCodec_BasicModule;
- m_pFaxModule = new CCodec_FaxModule;
- m_pJpegModule = new CCodec_JpegModule;
- m_pJpxModule = new CCodec_JpxModule;
- m_pJbig2Module = new CCodec_Jbig2Module;
- m_pIccModule = new CCodec_IccModule;
- m_pPngModule = new CCodec_PngModule;
- m_pGifModule = new CCodec_GifModule;
- m_pBmpModule = new CCodec_BmpModule;
- m_pTiffModule = new CCodec_TiffModule;
- m_pFlateModule = new CCodec_FlateModule;
-}
-CCodec_ModuleMgr::~CCodec_ModuleMgr()
-{
- delete m_pBasicModule;
- delete m_pFaxModule;
- delete m_pJpegModule;
- delete m_pFlateModule;
- delete m_pJpxModule;
- delete m_pJbig2Module;
- delete m_pIccModule;
-}
-void CCodec_ModuleMgr::InitJbig2Decoder()
-{
-}
-void CCodec_ModuleMgr::InitJpxDecoder()
-{
-}
-void CCodec_ModuleMgr::InitIccDecoder()
-{
+ : m_pBasicModule(new CCodec_BasicModule),
+ m_pFaxModule(new CCodec_FaxModule),
+ m_pJpegModule(new CCodec_JpegModule),
+ m_pJpxModule(new CCodec_JpxModule),
+ m_pJbig2Module(new CCodec_Jbig2Module),
+ m_pIccModule(new CCodec_IccModule),
+ m_pFlateModule(new CCodec_FlateModule),
+ m_pPngModule(new CCodec_PngModule),
+ m_pGifModule(new CCodec_GifModule),
+ m_pBmpModule(new CCodec_BmpModule),
+ m_pTiffModule(new CCodec_TiffModule) {
}
CCodec_ScanlineDecoder::CCodec_ScanlineDecoder()
{
@@ -245,14 +226,6 @@ FX_BOOL CCodec_BasicModule::A85Encode(const uint8_t* src_buf, FX_DWORD src_size,
{
return FALSE;
}
-CCodec_ModuleMgr* CCodec_ModuleMgr::Create()
-{
- return new CCodec_ModuleMgr;
-}
-void CCodec_ModuleMgr::Destroy()
-{
- delete this;
-}
CFX_DIBAttribute::CFX_DIBAttribute()
{
FXSYS_memset(this, 0, sizeof(CFX_DIBAttribute));