diff options
Diffstat (limited to 'core/fpdfapi')
-rw-r--r-- | core/fpdfapi/cpdf_modulemgr.cpp (renamed from core/fpdfapi/fpdf_basic_module.cpp) | 10 | ||||
-rw-r--r-- | core/fpdfapi/include/cpdf_modulemgr.h | 19 |
2 files changed, 9 insertions, 20 deletions
diff --git a/core/fpdfapi/fpdf_basic_module.cpp b/core/fpdfapi/cpdf_modulemgr.cpp index 75450bf975..fe5368d3f7 100644 --- a/core/fpdfapi/fpdf_basic_module.cpp +++ b/core/fpdfapi/cpdf_modulemgr.cpp @@ -36,16 +36,6 @@ CPDF_ModuleMgr::CPDF_ModuleMgr() : m_pCodecModule(nullptr) {} CPDF_ModuleMgr::~CPDF_ModuleMgr() {} -void CPDF_ModuleMgr::SetPrivateData(void* module_id, - void* pData, - PD_CALLBACK_FREEDATA callback) { - m_privateData.SetPrivateData(module_id, pData, callback); -} - -void* CPDF_ModuleMgr::GetPrivateData(void* module_id) { - return m_privateData.GetPrivateData(module_id); -} - CCodec_FaxModule* CPDF_ModuleMgr::GetFaxModule() { return m_pCodecModule ? m_pCodecModule->GetFaxModule() : nullptr; } diff --git a/core/fpdfapi/include/cpdf_modulemgr.h b/core/fpdfapi/include/cpdf_modulemgr.h index e54bd07a90..95c5385e64 100644 --- a/core/fpdfapi/include/cpdf_modulemgr.h +++ b/core/fpdfapi/include/cpdf_modulemgr.h @@ -11,14 +11,13 @@ #include "core/fxcrt/include/fx_basic.h" -class CCodec_ModuleMgr; class CCodec_FaxModule; class CCodec_FlateModule; class CCodec_IccModule; class CCodec_Jbig2Module; class CCodec_JpegModule; class CCodec_JpxModule; - +class CCodec_ModuleMgr; class CPDF_PageModule; class CPDF_ModuleMgr { @@ -32,9 +31,15 @@ class CPDF_ModuleMgr { CCodec_ModuleMgr* GetCodecModule() { return m_pCodecModule; } void InitPageModule(); - CPDF_PageModule* GetPageModule() const { return m_pPageModule.get(); } + void SetUnsupportInfoAdapter(std::unique_ptr<CFX_Deletable> pAdapter) { + m_pUnsupportInfoAdapter = std::move(pAdapter); + } + CFX_Deletable* GetUnsupportInfoAdapter() const { + return m_pUnsupportInfoAdapter.get(); + } + void LoadEmbeddedGB1CMaps(); void LoadEmbeddedCNS1CMaps(); void LoadEmbeddedJapan1CMaps(); @@ -47,19 +52,13 @@ class CPDF_ModuleMgr { CCodec_IccModule* GetIccModule(); CCodec_FlateModule* GetFlateModule(); - void SetPrivateData(void* module_id, - void* pData, - PD_CALLBACK_FREEDATA callback); - - void* GetPrivateData(void* module_id); - private: CPDF_ModuleMgr(); ~CPDF_ModuleMgr(); CCodec_ModuleMgr* m_pCodecModule; std::unique_ptr<CPDF_PageModule> m_pPageModule; - CFX_PrivateData m_privateData; + std::unique_ptr<CFX_Deletable> m_pUnsupportInfoAdapter; }; #endif // CORE_FPDFAPI_INCLUDE_CPDF_MODULEMGR_H_ |