From 77be04971c130cadbbdba04814f3d77ef25548bc Mon Sep 17 00:00:00 2001 From: npm Date: Tue, 30 Aug 2016 15:56:24 -0700 Subject: Clean up CPDF_CMap declaration - Removed unused methods - Friendship with CPDF_PathManager is not needed - Protected may be changed to private Review-Url: https://codereview.chromium.org/2292023003 --- core/fpdfapi/fpdf_font/font_int.h | 5 +---- core/fpdfapi/fpdf_font/fpdf_font_cid.cpp | 5 ----- 2 files changed, 1 insertion(+), 9 deletions(-) diff --git a/core/fpdfapi/fpdf_font/font_int.h b/core/fpdfapi/fpdf_font/font_int.h index c1e2f75599..a09bb6bce6 100644 --- a/core/fpdfapi/fpdf_font/font_int.h +++ b/core/fpdfapi/fpdf_font/font_int.h @@ -142,20 +142,17 @@ class CPDF_CMap { const FX_CHAR* name, FX_BOOL bPromptCJK); FX_BOOL LoadEmbedded(const uint8_t* pData, uint32_t dwSize); - void Release(); FX_BOOL IsLoaded() const; FX_BOOL IsVertWriting() const; uint16_t CIDFromCharCode(uint32_t charcode) const; - uint32_t CharCodeFromCID(uint16_t CID) const; int GetCharSize(uint32_t charcode) const; uint32_t GetNextChar(const FX_CHAR* pString, int nStrLen, int& offset) const; int CountChar(const FX_CHAR* pString, int size) const; int AppendChar(FX_CHAR* str, uint32_t charcode) const; - protected: + private: friend class CPDF_CMapParser; - friend class CPDF_CMapManager; friend class CPDF_CIDFont; CFX_ByteString m_PredefinedCMap; diff --git a/core/fpdfapi/fpdf_font/fpdf_font_cid.cpp b/core/fpdfapi/fpdf_font/fpdf_font_cid.cpp index cfcac364b9..d8cada7af3 100644 --- a/core/fpdfapi/fpdf_font/fpdf_font_cid.cpp +++ b/core/fpdfapi/fpdf_font/fpdf_font_cid.cpp @@ -518,11 +518,6 @@ CPDF_CMap::~CPDF_CMap() { FX_Free(m_pAddMapping); FX_Free(m_pLeadingBytes); } -void CPDF_CMap::Release() { - if (m_PredefinedCMap.IsEmpty()) { - delete this; - } -} FX_BOOL CPDF_CMap::IsLoaded() const { return m_bLoaded; -- cgit v1.2.3