summaryrefslogtreecommitdiff
path: root/core
diff options
context:
space:
mode:
authorTom Sepez <tsepez@chromium.org>2015-08-14 12:59:52 -0700
committerTom Sepez <tsepez@chromium.org>2015-08-14 12:59:52 -0700
commitfc9c930aef756d1567afae53f9c20935166c99f3 (patch)
tree0001536970eed57d8f40b44efc9fac7afda54388 /core
parent7e4600f3382d1c0916d0114761e67d153da97416 (diff)
downloadpdfium-fc9c930aef756d1567afae53f9c20935166c99f3.tar.xz
Merge to XFA: CPDF_ModuleMgr::m_SecurityHandlerMap only used by dead code.
(cherry picked from commit f372567fdb84df1c8b2cd3735575d6d9881e7871) Original Review URL: https://codereview.chromium.org/1289693008 . TBR=thestig@chromium.org Review URL: https://codereview.chromium.org/1293913002 .
Diffstat (limited to 'core')
-rw-r--r--core/include/fpdfapi/fpdf_module.h20
-rw-r--r--core/src/fpdfapi/fpdf_basic_module.cpp41
2 files changed, 0 insertions, 61 deletions
diff --git a/core/include/fpdfapi/fpdf_module.h b/core/include/fpdfapi/fpdf_module.h
index bfa051ed4c..2f88644041 100644
--- a/core/include/fpdfapi/fpdf_module.h
+++ b/core/include/fpdfapi/fpdf_module.h
@@ -50,17 +50,9 @@ class CPDF_ModuleMgr {
CCodec_ModuleMgr* GetCodecModule() { return m_pCodecModule; }
void InitPageModule();
-
void InitRenderModule();
- void SetDownloadCallback(FX_BOOL (*callback)(const FX_CHAR* module_name));
-
- FX_BOOL DownloadModule(const FX_CHAR* module_name);
-
- void NotifyModuleAvailable(const FX_CHAR* module_name);
-
IPDF_RenderModule* GetRenderModule() const { return m_pRenderModule.get(); }
-
IPDF_PageModule* GetPageModule() const { return m_pPageModule.get(); }
void LoadEmbeddedGB1CMaps();
@@ -75,13 +67,6 @@ class CPDF_ModuleMgr {
ICodec_IccModule* GetIccModule();
ICodec_FlateModule* GetFlateModule();
- void RegisterSecurityHandler(
- const FX_CHAR* name,
- CPDF_SecurityHandler* (*CreateHandler)(void* param),
- void* param);
-
- CPDF_SecurityHandler* CreateSecurityHandler(const FX_CHAR* name);
-
void SetPrivateData(void* module_id,
void* pData,
PD_CALLBACK_FREEDATA callback);
@@ -93,14 +78,9 @@ class CPDF_ModuleMgr {
~CPDF_ModuleMgr();
CCodec_ModuleMgr* m_pCodecModule;
-
nonstd::unique_ptr<IPDF_RenderModule> m_pRenderModule;
nonstd::unique_ptr<IPDF_PageModule> m_pPageModule;
-
FX_BOOL (*m_pDownloadCallback)(const FX_CHAR* module_name);
-
- CFX_MapByteStringToPtr m_SecurityHandlerMap;
-
CFX_PrivateData m_privateData;
};
diff --git a/core/src/fpdfapi/fpdf_basic_module.cpp b/core/src/fpdfapi/fpdf_basic_module.cpp
index 595dadbf69..198f1318be 100644
--- a/core/src/fpdfapi/fpdf_basic_module.cpp
+++ b/core/src/fpdfapi/fpdf_basic_module.cpp
@@ -36,34 +36,6 @@ CPDF_ModuleMgr::CPDF_ModuleMgr() : m_pCodecModule(nullptr) {}
CPDF_ModuleMgr::~CPDF_ModuleMgr() {}
-void CPDF_ModuleMgr::SetDownloadCallback(
- FX_BOOL (*callback)(const FX_CHAR* module_name)) {
- m_pDownloadCallback = callback;
-}
-FX_BOOL CPDF_ModuleMgr::DownloadModule(const FX_CHAR* module_name) {
- if (m_pDownloadCallback == NULL) {
- return FALSE;
- }
- return m_pDownloadCallback(module_name);
-}
-void CPDF_ModuleMgr::NotifyModuleAvailable(const FX_CHAR* module_name) {
- if (FXSYS_strcmp(module_name, kAddinNameCJK) == 0) {
- m_pPageModule->NotifyCJKAvailable();
- }
-}
-void CPDF_ModuleMgr::RegisterSecurityHandler(
- const FX_CHAR* filter,
- CPDF_SecurityHandler* (*CreateHandler)(void* param),
- void* param) {
- if (CreateHandler == NULL) {
- m_SecurityHandlerMap.RemoveKey(filter);
- } else {
- m_SecurityHandlerMap.SetAt(filter, (void*)CreateHandler);
- }
- if (param) {
- m_SecurityHandlerMap.SetAt(FX_BSTRC("_param_") + filter, param);
- }
-}
void CPDF_ModuleMgr::SetPrivateData(void* module_id,
void* pData,
PD_CALLBACK_FREEDATA callback) {
@@ -72,19 +44,6 @@ void CPDF_ModuleMgr::SetPrivateData(void* module_id,
void* CPDF_ModuleMgr::GetPrivateData(void* module_id) {
return m_privateData.GetPrivateData(module_id);
}
-CPDF_SecurityHandler* CPDF_ModuleMgr::CreateSecurityHandler(
- const FX_CHAR* filter) {
- CPDF_SecurityHandler* (*CreateHandler)(void*) = NULL;
- if (!m_SecurityHandlerMap.Lookup(filter, (void*&)CreateHandler)) {
- return NULL;
- }
- if (CreateHandler == NULL) {
- return NULL;
- }
- void* param = NULL;
- m_SecurityHandlerMap.Lookup(FX_BSTRC("_param_") + filter, param);
- return CreateHandler(param);
-}
ICodec_FaxModule* CPDF_ModuleMgr::GetFaxModule() {
return m_pCodecModule ? m_pCodecModule->GetFaxModule() : NULL;
}