summaryrefslogtreecommitdiff
path: root/core/src/fxge
diff options
context:
space:
mode:
authorDan Sinclair <dsinclair@chromium.org>2016-03-07 17:08:39 -0500
committerDan Sinclair <dsinclair@chromium.org>2016-03-07 17:08:39 -0500
commit594912241cd7d409b5f58a48ccffdc1904d844b2 (patch)
treeadcdb712f0cfa4cb07d1a490b2d45f15362b4329 /core/src/fxge
parentc582c0ddfea8ba01c8449ed7841cdb33c12e0a98 (diff)
downloadpdfium-594912241cd7d409b5f58a48ccffdc1904d844b2.tar.xz
Revert "Fix chromium-style errors."
This reverts commit c582c0ddfea8ba01c8449ed7841cdb33c12e0a98. TBR=tsepez@chromium.org Review URL: https://codereview.chromium.org/1769263002 .
Diffstat (limited to 'core/src/fxge')
-rw-r--r--core/src/fxge/dib/fx_dib_main.cpp40
-rw-r--r--core/src/fxge/ge/fx_ge_fontmap.cpp17
-rw-r--r--core/src/fxge/ge/fx_ge_text.cpp3
3 files changed, 8 insertions, 52 deletions
diff --git a/core/src/fxge/dib/fx_dib_main.cpp b/core/src/fxge/dib/fx_dib_main.cpp
index ab4c170af5..4922373ec0 100644
--- a/core/src/fxge/dib/fx_dib_main.cpp
+++ b/core/src/fxge/dib/fx_dib_main.cpp
@@ -42,7 +42,6 @@ FX_DWORD ArgbEncode(int a, FX_COLORREF rgb) {
return FXARGB_MAKE(a, FXSYS_GetRValue(rgb), FXSYS_GetGValue(rgb),
FXSYS_GetBValue(rgb));
}
-
CFX_DIBSource::CFX_DIBSource() {
m_bpp = 0;
m_AlphaFlag = 0;
@@ -51,26 +50,15 @@ CFX_DIBSource::CFX_DIBSource() {
m_pPalette = NULL;
m_pAlphaMask = NULL;
}
-
CFX_DIBSource::~CFX_DIBSource() {
FX_Free(m_pPalette);
delete m_pAlphaMask;
}
-
-uint8_t* CFX_DIBSource::GetBuffer() const {
- return NULL;
-}
-
-FX_BOOL CFX_DIBSource::SkipToScanline(int line, IFX_Pause* pPause) const {
- return FALSE;
-}
-
CFX_DIBitmap::CFX_DIBitmap() {
m_bExtBuf = FALSE;
m_pBuffer = NULL;
m_pPalette = NULL;
}
-
#define _MAX_OOM_LIMIT_ 12000000
FX_BOOL CFX_DIBitmap::Create(int width,
int height,
@@ -125,7 +113,6 @@ FX_BOOL CFX_DIBitmap::Create(int width,
}
return TRUE;
}
-
FX_BOOL CFX_DIBitmap::Copy(const CFX_DIBSource* pSrc) {
if (m_pBuffer) {
return FALSE;
@@ -140,34 +127,24 @@ FX_BOOL CFX_DIBitmap::Copy(const CFX_DIBSource* pSrc) {
}
return TRUE;
}
-
CFX_DIBitmap::~CFX_DIBitmap() {
- if (!m_bExtBuf)
+ if (!m_bExtBuf) {
FX_Free(m_pBuffer);
-
- m_pBuffer = nullptr;
-}
-
-uint8_t* CFX_DIBitmap::GetBuffer() const {
- return m_pBuffer;
-}
-
-const uint8_t* CFX_DIBitmap::GetScanline(int line) const {
- return m_pBuffer ? m_pBuffer + line * m_Pitch : nullptr;
+ }
+ m_pBuffer = NULL;
}
-
void CFX_DIBitmap::TakeOver(CFX_DIBitmap* pSrcBitmap) {
- if (!m_bExtBuf)
+ if (!m_bExtBuf) {
FX_Free(m_pBuffer);
-
+ }
FX_Free(m_pPalette);
delete m_pAlphaMask;
m_pBuffer = pSrcBitmap->m_pBuffer;
m_pPalette = pSrcBitmap->m_pPalette;
m_pAlphaMask = pSrcBitmap->m_pAlphaMask;
- pSrcBitmap->m_pBuffer = nullptr;
- pSrcBitmap->m_pPalette = nullptr;
- pSrcBitmap->m_pAlphaMask = nullptr;
+ pSrcBitmap->m_pBuffer = NULL;
+ pSrcBitmap->m_pPalette = NULL;
+ pSrcBitmap->m_pAlphaMask = NULL;
m_bpp = pSrcBitmap->m_bpp;
m_bExtBuf = pSrcBitmap->m_bExtBuf;
m_AlphaFlag = pSrcBitmap->m_AlphaFlag;
@@ -175,7 +152,6 @@ void CFX_DIBitmap::TakeOver(CFX_DIBitmap* pSrcBitmap) {
m_Height = pSrcBitmap->m_Height;
m_Pitch = pSrcBitmap->m_Pitch;
}
-
CFX_DIBitmap* CFX_DIBSource::Clone(const FX_RECT* pClip) const {
FX_RECT rect(0, 0, m_Width, m_Height);
if (pClip) {
diff --git a/core/src/fxge/ge/fx_ge_fontmap.cpp b/core/src/fxge/ge/fx_ge_fontmap.cpp
index cd46148b7f..890de616d1 100644
--- a/core/src/fxge/ge/fx_ge_fontmap.cpp
+++ b/core/src/fxge/ge/fx_ge_fontmap.cpp
@@ -1281,23 +1281,8 @@ FXFT_Face CFX_FontMapper::FindSubstFontByUnicode(FX_DWORD dwUnicode,
m_pFontInfo->DeleteFont(hFont);
return face;
}
-
-void* IFX_SystemFontInfo::MapFontByUnicode(FX_DWORD dwUnicode,
- int weight,
- FX_BOOL bItalic,
- int pitch_family) {
- return nullptr;
-}
#endif // PDF_ENABLE_XFA
-int IFX_SystemFontInfo::GetFaceIndex(void* hFont) {
- return 0;
-}
-
-void* IFX_SystemFontInfo::RetainFont(void* hFont) {
- return NULL;
-}
-
int CFX_FontMapper::GetFaceSize() const {
return pdfium::CollectionSize<int>(m_FaceArray);
}
@@ -1323,13 +1308,11 @@ unsigned long _FTStreamRead(FXFT_Stream stream,
unsigned long count);
void _FTStreamClose(FXFT_Stream stream);
};
-
#if _FX_OS_ == _FX_ANDROID_
IFX_SystemFontInfo* IFX_SystemFontInfo::CreateDefault(const char** pUnused) {
return NULL;
}
#endif
-
CFX_FolderFontInfo::CFX_FolderFontInfo() {}
CFX_FolderFontInfo::~CFX_FolderFontInfo() {
for (const auto& pair : m_FontList) {
diff --git a/core/src/fxge/ge/fx_ge_text.cpp b/core/src/fxge/ge/fx_ge_text.cpp
index 8fb03d86eb..8d54363d14 100644
--- a/core/src/fxge/ge/fx_ge_text.cpp
+++ b/core/src/fxge/ge/fx_ge_text.cpp
@@ -1167,9 +1167,6 @@ FX_BOOL CFX_RenderDevice::DrawTextPath(int nChars,
}
return TRUE;
}
-
-CFX_FontCache::CFX_FontCache() {}
-
CFX_FontCache::~CFX_FontCache() {
FreeCache(TRUE);
}