summaryrefslogtreecommitdiff
path: root/core/src
diff options
context:
space:
mode:
authorTom Sepez <tsepez@chromium.org>2015-06-09 11:29:12 -0700
committerTom Sepez <tsepez@chromium.org>2015-06-09 11:29:12 -0700
commitb116136da234afcad018bb44a3ccb64b9ad2a554 (patch)
treee81b2016bc21485d1d6bdc7c1a5c65f610f18b20 /core/src
parentb69545dd059b8a5bb3695969e622462559c97276 (diff)
downloadpdfium-b116136da234afcad018bb44a3ccb64b9ad2a554.tar.xz
Merge to XFA: Remove more cruft from fx_system.h
New manual edits in the following to fix compilation: fx_bmp.h, fx_gif.h, fx_graphics.h Original Review URL: https://codereview.chromium.org/1169963003 R=thestig@chromium.org Review URL: https://codereview.chromium.org/1170103004
Diffstat (limited to 'core/src')
-rw-r--r--core/src/fpdfapi/fpdf_edit/fpdf_edit_doc.cpp2
-rw-r--r--core/src/fpdfapi/fpdf_font/ttgsubtable.h6
-rw-r--r--core/src/fpdfapi/fpdf_parser/fpdf_parser_parser.cpp16
-rw-r--r--core/src/fpdfdoc/tagged_int.h2
-rw-r--r--core/src/fxcodec/codec/fx_codec_jpeg.cpp2
-rw-r--r--core/src/fxcodec/lbmp/fx_bmp.h5
-rw-r--r--core/src/fxcodec/lgif/fx_gif.h5
-rw-r--r--core/src/fxcrt/extension.h58
-rw-r--r--core/src/fxcrt/fx_arabic.h14
-rw-r--r--core/src/fxge/apple/apple_int.h14
-rw-r--r--core/src/fxge/ge/fx_ge_fontmap.cpp4
-rw-r--r--core/src/fxge/win32/fx_win32_device.cpp4
-rw-r--r--core/src/fxge/win32/fx_win32_dib.cpp2
-rw-r--r--core/src/fxge/win32/fx_win32_dwrite.cpp6
-rw-r--r--core/src/fxge/win32/fx_win32_gdipext.cpp4
-rw-r--r--core/src/fxge/win32/fx_win32_print.cpp2
16 files changed, 76 insertions, 70 deletions
diff --git a/core/src/fpdfapi/fpdf_edit/fpdf_edit_doc.cpp b/core/src/fpdfapi/fpdf_edit/fpdf_edit_doc.cpp
index 9d0967978c..e75fd079bf 100644
--- a/core/src/fpdfapi/fpdf_edit/fpdf_edit_doc.cpp
+++ b/core/src/fpdfapi/fpdf_edit/fpdf_edit_doc.cpp
@@ -191,7 +191,7 @@ const FX_CharsetUnicodes g_FX_CharsetUnicodes[] = {
{ FXFONT_ARABIC_CHARSET, g_FX_CP1256Unicodes },
{ FXFONT_BALTIC_CHARSET, g_FX_CP1257Unicodes },
};
-#if (_FX_OS_ == _FX_WIN32_DESKTOP_ || _FX_OS_ == _FX_WIN32_MOBILE_ || _FX_OS_ == _FX_WIN64_)
+#if (_FX_OS_ == _FX_WIN32_DESKTOP_ || _FX_OS_ == _FX_WIN64_DESKTOP_)
static void _InsertWidthArray(HDC hDC, int start, int end, CPDF_Array* pWidthArray)
{
int size = end - start + 1;
diff --git a/core/src/fpdfapi/fpdf_font/ttgsubtable.h b/core/src/fpdfapi/fpdf_font/ttgsubtable.h
index adfff6756a..cee68c0029 100644
--- a/core/src/fpdfapi/fpdf_font/ttgsubtable.h
+++ b/core/src/fpdfapi/fpdf_font/ttgsubtable.h
@@ -408,14 +408,14 @@ private:
struct TFeatureList FeatureList;
struct TLookupList LookupList;
};
-class CFX_GSUBTable FX_FINAL : public IFX_GSUBTable
+class CFX_GSUBTable final : public IFX_GSUBTable
{
public:
- virtual void Release() FX_OVERRIDE
+ virtual void Release() override
{
delete this;
}
- virtual FX_BOOL GetVerticalGlyph(FX_DWORD glyphnum, FX_DWORD* vglyphnum) FX_OVERRIDE;
+ virtual FX_BOOL GetVerticalGlyph(FX_DWORD glyphnum, FX_DWORD* vglyphnum) override;
CFX_CTTGSUBTable m_GsubImp;
diff --git a/core/src/fpdfapi/fpdf_parser/fpdf_parser_parser.cpp b/core/src/fpdfapi/fpdf_parser/fpdf_parser_parser.cpp
index e54f503380..9c35615a72 100644
--- a/core/src/fpdfapi/fpdf_parser/fpdf_parser_parser.cpp
+++ b/core/src/fpdfapi/fpdf_parser/fpdf_parser_parser.cpp
@@ -2722,28 +2722,28 @@ void CPDF_SyntaxParser::GetBinary(FX_BYTE* buffer, FX_DWORD size)
}
}
-class CPDF_DataAvail FX_FINAL : public IPDF_DataAvail
+class CPDF_DataAvail final : public IPDF_DataAvail
{
public:
CPDF_DataAvail(IFX_FileAvail* pFileAvail, IFX_FileRead* pFileRead);
~CPDF_DataAvail();
- virtual FX_BOOL IsDocAvail(IFX_DownloadHints* pHints) FX_OVERRIDE;
+ virtual FX_BOOL IsDocAvail(IFX_DownloadHints* pHints) override;
- virtual void SetDocument(CPDF_Document* pDoc) FX_OVERRIDE;
+ virtual void SetDocument(CPDF_Document* pDoc) override;
- virtual FX_BOOL IsPageAvail(int iPage, IFX_DownloadHints* pHints) FX_OVERRIDE;
+ virtual FX_BOOL IsPageAvail(int iPage, IFX_DownloadHints* pHints) override;
- virtual FX_INT32 IsFormAvail(IFX_DownloadHints *pHints) FX_OVERRIDE;
+ virtual FX_INT32 IsFormAvail(IFX_DownloadHints *pHints) override;
- virtual FX_INT32 IsLinearizedPDF() FX_OVERRIDE;
+ virtual FX_INT32 IsLinearizedPDF() override;
- virtual FX_BOOL IsLinearized() FX_OVERRIDE
+ virtual FX_BOOL IsLinearized() override
{
return m_bLinearized;
}
- virtual void GetLinearizedMainXRefInfo(FX_FILESIZE *pPos, FX_DWORD *pSize) FX_OVERRIDE;
+ virtual void GetLinearizedMainXRefInfo(FX_FILESIZE *pPos, FX_DWORD *pSize) override;
protected:
static const int kMaxDataAvailRecursionDepth = 64;
diff --git a/core/src/fpdfdoc/tagged_int.h b/core/src/fpdfdoc/tagged_int.h
index 75004e51fa..44ba527a60 100644
--- a/core/src/fpdfdoc/tagged_int.h
+++ b/core/src/fpdfdoc/tagged_int.h
@@ -34,7 +34,7 @@ protected:
CFX_ArrayTemplate<CPDF_StructElementImpl*> m_Kids;
friend class CPDF_StructElementImpl;
};
-class CPDF_StructElementImpl FX_FINAL : public CPDF_StructElement
+class CPDF_StructElementImpl final : public CPDF_StructElement
{
public:
CPDF_StructElementImpl(CPDF_StructTreeImpl* pTree, CPDF_StructElementImpl* pParent, CPDF_Dictionary* pDict);
diff --git a/core/src/fxcodec/codec/fx_codec_jpeg.cpp b/core/src/fxcodec/codec/fx_codec_jpeg.cpp
index 903d2319fd..7d18cb599f 100644
--- a/core/src/fxcodec/codec/fx_codec_jpeg.cpp
+++ b/core/src/fxcodec/codec/fx_codec_jpeg.cpp
@@ -4,6 +4,8 @@
// Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
+#include <setjmp.h>
+
#include "../../../include/fxcodec/fx_codec.h"
#include "../../../include/fxcrt/fx_safe_types.h"
#include "../../../include/fxge/fx_dib.h"
diff --git a/core/src/fxcodec/lbmp/fx_bmp.h b/core/src/fxcodec/lbmp/fx_bmp.h
index 1603770eb4..b7c3617182 100644
--- a/core/src/fxcodec/lbmp/fx_bmp.h
+++ b/core/src/fxcodec/lbmp/fx_bmp.h
@@ -4,9 +4,10 @@
// Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
-#ifndef _FX_BASIC_H_
+#include <setjmp.h>
+
#include "../../../include/fxcrt/fx_basic.h"
-#endif
+
#define BMP_SUPPORT_BITFIELD
#define BMP_WIDTHBYTES(width,bitCount) ((width*bitCount) + 31)/32*4
#define BMP_PAL_ENCODE(a,r,g,b) (((FX_DWORD)(a) << 24) | ((r) << 16) | ((g) << 8) | (b))
diff --git a/core/src/fxcodec/lgif/fx_gif.h b/core/src/fxcodec/lgif/fx_gif.h
index 3d2b232267..09c63e20f6 100644
--- a/core/src/fxcodec/lgif/fx_gif.h
+++ b/core/src/fxcodec/lgif/fx_gif.h
@@ -4,9 +4,10 @@
// Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
-#ifndef _FX_BASIC_H_
+#include <setjmp.h>
+
#include "../../../include/fxcrt/fx_basic.h"
-#endif
+
extern FX_WORD _GetWord_LSBFirst(FX_LPBYTE p);
extern void _SetWord_LSBFirst(FX_LPBYTE p, FX_WORD v);
extern void _BpcConvert(FX_LPCBYTE src_buf, FX_DWORD src_len, FX_INT32 src_bpc, FX_INT32 dst_bpc,
diff --git a/core/src/fxcrt/extension.h b/core/src/fxcrt/extension.h
index 0f37bbfefc..86e46eb5a0 100644
--- a/core/src/fxcrt/extension.h
+++ b/core/src/fxcrt/extension.h
@@ -66,7 +66,7 @@ protected:
CFX_WideString m_path;
FX_DWORD m_RefCount;
};
-class CFX_CRTFileStream FX_FINAL : public IFX_FileStream
+class CFX_CRTFileStream final : public IFX_FileStream
{
public:
CFX_CRTFileStream(IFXCRT_FileAccess* pFA) : m_pFile(pFA), m_dwCount(1), m_bUseRange(FALSE), m_nOffset(0), m_nSize(0) {}
@@ -76,27 +76,27 @@ public:
m_pFile->Release();
}
}
- virtual IFX_FileStream* Retain() FX_OVERRIDE
+ virtual IFX_FileStream* Retain() override
{
m_dwCount ++;
return this;
}
- virtual void Release() FX_OVERRIDE
+ virtual void Release() override
{
FX_DWORD nCount = -- m_dwCount;
if (!nCount) {
delete this;
}
}
- virtual FX_FILESIZE GetSize() FX_OVERRIDE
+ virtual FX_FILESIZE GetSize() override
{
return m_bUseRange ? m_nSize : m_pFile->GetSize();
}
- virtual FX_BOOL IsEOF() FX_OVERRIDE
+ virtual FX_BOOL IsEOF() override
{
return GetPosition() >= GetSize();
}
- virtual FX_FILESIZE GetPosition() FX_OVERRIDE
+ virtual FX_FILESIZE GetPosition() override
{
FX_FILESIZE pos = m_pFile->GetPosition();
if (m_bUseRange) {
@@ -104,7 +104,7 @@ public:
}
return pos;
}
- virtual FX_BOOL SetRange(FX_FILESIZE offset, FX_FILESIZE size) FX_OVERRIDE
+ virtual FX_BOOL SetRange(FX_FILESIZE offset, FX_FILESIZE size) override
{
if (offset < 0 || size < 0) {
return FALSE;
@@ -122,11 +122,11 @@ public:
m_pFile->SetPosition(m_nOffset);
return TRUE;
}
- virtual void ClearRange() FX_OVERRIDE
+ virtual void ClearRange() override
{
m_bUseRange = FALSE;
}
- virtual FX_BOOL ReadBlock(void* buffer, FX_FILESIZE offset, size_t size) FX_OVERRIDE
+ virtual FX_BOOL ReadBlock(void* buffer, FX_FILESIZE offset, size_t size) override
{
if (m_bUseRange && offset < 0) {
return FALSE;
@@ -141,7 +141,7 @@ public:
}
return (FX_BOOL)m_pFile->ReadPos(buffer, size, pos.ValueOrDie());
}
- virtual size_t ReadBlock(void* buffer, size_t size) FX_OVERRIDE
+ virtual size_t ReadBlock(void* buffer, size_t size) override
{
if (m_bUseRange) {
FX_FILESIZE availSize = m_nOffset + m_nSize - m_pFile->GetPosition();
@@ -151,14 +151,14 @@ public:
}
return m_pFile->Read(buffer, size);
}
- virtual FX_BOOL WriteBlock(const void* buffer, FX_FILESIZE offset, size_t size) FX_OVERRIDE
+ virtual FX_BOOL WriteBlock(const void* buffer, FX_FILESIZE offset, size_t size) override
{
if (m_bUseRange) {
offset += m_nOffset;
}
return (FX_BOOL)m_pFile->WritePos(buffer, size, offset);
}
- virtual FX_BOOL Flush() FX_OVERRIDE
+ virtual FX_BOOL Flush() override
{
return m_pFile->Flush();
}
@@ -171,7 +171,7 @@ public:
#define FX_MEMSTREAM_BlockSize (64 * 1024)
#define FX_MEMSTREAM_Consecutive 0x01
#define FX_MEMSTREAM_TakeOver 0x02
-class CFX_MemoryStream FX_FINAL : public IFX_MemoryStream
+class CFX_MemoryStream final : public IFX_MemoryStream
{
public:
CFX_MemoryStream(FX_BOOL bConsecutive)
@@ -204,12 +204,12 @@ public:
}
m_Blocks.RemoveAll();
}
- virtual IFX_FileStream* Retain() FX_OVERRIDE
+ virtual IFX_FileStream* Retain() override
{
m_dwCount ++;
return this;
}
- virtual void Release() FX_OVERRIDE
+ virtual void Release() override
{
FX_DWORD nCount = -- m_dwCount;
if (nCount) {
@@ -217,15 +217,15 @@ public:
}
delete this;
}
- virtual FX_FILESIZE GetSize() FX_OVERRIDE
+ virtual FX_FILESIZE GetSize() override
{
return m_bUseRange ? (FX_FILESIZE) m_nSize : (FX_FILESIZE)m_nCurSize;
}
- virtual FX_BOOL IsEOF() FX_OVERRIDE
+ virtual FX_BOOL IsEOF() override
{
return m_nCurPos >= (size_t)GetSize();
}
- virtual FX_FILESIZE GetPosition() FX_OVERRIDE
+ virtual FX_FILESIZE GetPosition() override
{
FX_FILESIZE pos = (FX_FILESIZE)m_nCurPos;
if (m_bUseRange) {
@@ -233,7 +233,7 @@ public:
}
return pos;
}
- virtual FX_BOOL SetRange(FX_FILESIZE offset, FX_FILESIZE size) FX_OVERRIDE
+ virtual FX_BOOL SetRange(FX_FILESIZE offset, FX_FILESIZE size) override
{
if (offset < 0 || size < 0) {
return FALSE;
@@ -249,11 +249,11 @@ public:
m_nCurPos = m_nOffset;
return TRUE;
}
- virtual void ClearRange() FX_OVERRIDE
+ virtual void ClearRange() override
{
m_bUseRange = FALSE;
}
- virtual FX_BOOL ReadBlock(void* buffer, FX_FILESIZE offset, size_t size) FX_OVERRIDE
+ virtual FX_BOOL ReadBlock(void* buffer, FX_FILESIZE offset, size_t size) override
{
if (!buffer || !size) {
return FALSE;
@@ -296,7 +296,7 @@ public:
}
return TRUE;
}
- virtual size_t ReadBlock(void* buffer, size_t size) FX_OVERRIDE
+ virtual size_t ReadBlock(void* buffer, size_t size) override
{
if (m_nCurPos >= m_nCurSize) {
return 0;
@@ -313,7 +313,7 @@ public:
}
return nRead;
}
- virtual FX_BOOL WriteBlock(const void* buffer, FX_FILESIZE offset, size_t size) FX_OVERRIDE
+ virtual FX_BOOL WriteBlock(const void* buffer, FX_FILESIZE offset, size_t size) override
{
if (!buffer || !size) {
return FALSE;
@@ -373,15 +373,15 @@ public:
}
return TRUE;
}
- virtual FX_BOOL Flush() FX_OVERRIDE
+ virtual FX_BOOL Flush() override
{
return TRUE;
}
- virtual FX_BOOL IsConsecutive() const FX_OVERRIDE
+ virtual FX_BOOL IsConsecutive() const override
{
return m_dwFlags & FX_MEMSTREAM_Consecutive;
}
- virtual void EstimateSize(size_t nInitSize, size_t nGrowSize) FX_OVERRIDE
+ virtual void EstimateSize(size_t nInitSize, size_t nGrowSize) override
{
if (m_dwFlags & FX_MEMSTREAM_Consecutive) {
if (m_Blocks.GetSize() < 1) {
@@ -393,11 +393,11 @@ public:
m_nGrowSize = FX_MAX(nGrowSize, 4096);
}
}
- virtual FX_LPBYTE GetBuffer() const FX_OVERRIDE
+ virtual FX_LPBYTE GetBuffer() const override
{
return m_Blocks.GetSize() ? (FX_LPBYTE)m_Blocks[0] : NULL;
}
- virtual void AttachBuffer(FX_LPBYTE pBuffer, size_t nSize, FX_BOOL bTakeOver = FALSE) FX_OVERRIDE
+ virtual void AttachBuffer(FX_LPBYTE pBuffer, size_t nSize, FX_BOOL bTakeOver = FALSE) override
{
if (!(m_dwFlags & FX_MEMSTREAM_Consecutive)) {
return;
@@ -409,7 +409,7 @@ public:
m_dwFlags = FX_MEMSTREAM_Consecutive | (bTakeOver ? FX_MEMSTREAM_TakeOver : 0);
ClearRange();
}
- virtual void DetachBuffer() FX_OVERRIDE
+ virtual void DetachBuffer() override
{
if (!(m_dwFlags & FX_MEMSTREAM_Consecutive)) {
return;
diff --git a/core/src/fxcrt/fx_arabic.h b/core/src/fxcrt/fx_arabic.h
index cf221301f2..66e8bc8000 100644
--- a/core/src/fxcrt/fx_arabic.h
+++ b/core/src/fxcrt/fx_arabic.h
@@ -180,22 +180,22 @@ void FX_BidiResolveImplicit(const CFX_Int32Array &classes, CFX_Int32Array &level
void FX_BidiResolveWhitespace(FX_INT32 iBaseLevel, const CFX_Int32Array &classes, CFX_Int32Array &levels);
FX_INT32 FX_BidiReorderLevel(FX_INT32 iBaseLevel, CFX_WideString &wsText, const CFX_Int32Array &levels, FX_INT32 iStart, FX_BOOL bReverse = FALSE);
void FX_BidiReorder(FX_INT32 iBaseLevel, CFX_WideString &wsText, const CFX_Int32Array &levels);
-class CFX_BidiChar FX_FINAL : public IFX_BidiChar
+class CFX_BidiChar final : public IFX_BidiChar
{
public:
CFX_BidiChar();
- virtual void Release() FX_OVERRIDE
+ virtual void Release() override
{
delete this;
}
- virtual void SetPolicy(FX_BOOL bSeparateNeutral = TRUE) FX_OVERRIDE
+ virtual void SetPolicy(FX_BOOL bSeparateNeutral = TRUE) override
{
m_bSeparateNeutral = bSeparateNeutral;
}
- virtual FX_BOOL AppendChar(FX_WCHAR wch) FX_OVERRIDE;
- virtual FX_BOOL EndChar() FX_OVERRIDE;
- virtual FX_INT32 GetBidiInfo(FX_INT32 &iStart, FX_INT32 &iCount) FX_OVERRIDE;
- virtual void Reset() FX_OVERRIDE;
+ virtual FX_BOOL AppendChar(FX_WCHAR wch) override;
+ virtual FX_BOOL EndChar() override;
+ virtual FX_INT32 GetBidiInfo(FX_INT32 &iStart, FX_INT32 &iCount) override;
+ virtual void Reset() override;
private:
~CFX_BidiChar() { }
diff --git a/core/src/fxge/apple/apple_int.h b/core/src/fxge/apple/apple_int.h
index 5b083d83eb..2466ecbc9a 100644
--- a/core/src/fxge/apple/apple_int.h
+++ b/core/src/fxge/apple/apple_int.h
@@ -186,28 +186,28 @@ protected:
FX_INT32 _horzSize;
FX_INT32 _vertSize;
};
-class CFX_FontProvider FX_FINAL : public IFX_FileRead
+class CFX_FontProvider final : public IFX_FileRead
{
public:
- virtual void Release() FX_OVERRIDE
+ virtual void Release() override
{
delete this;
}
- virtual FX_FILESIZE GetSize() FX_OVERRIDE
+ virtual FX_FILESIZE GetSize() override
{
return (FX_FILESIZE)_totalSize;
}
- virtual FX_BOOL ReadBlock(void* buffer, FX_FILESIZE offset, size_t size) FX_OVERRIDE;
+ virtual FX_BOOL ReadBlock(void* buffer, FX_FILESIZE offset, size_t size) override;
- virtual FX_BOOL IsEOF() FX_OVERRIDE
+ virtual FX_BOOL IsEOF() override
{
return _offSet == _totalSize;
}
- virtual FX_FILESIZE GetPosition() FX_OVERRIDE
+ virtual FX_FILESIZE GetPosition() override
{
return (FX_FILESIZE)_offSet;
}
- virtual size_t ReadBlock(void* buffer, size_t size) FX_OVERRIDE;
+ virtual size_t ReadBlock(void* buffer, size_t size) override;
public:
CFX_FontProvider(CGFontRef cgFont);
~CFX_FontProvider();
diff --git a/core/src/fxge/ge/fx_ge_fontmap.cpp b/core/src/fxge/ge/fx_ge_fontmap.cpp
index ec4530b8ed..acae306d6f 100644
--- a/core/src/fxge/ge/fx_ge_fontmap.cpp
+++ b/core/src/fxge/ge/fx_ge_fontmap.cpp
@@ -4,6 +4,8 @@
// Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
+#include <limits>
+
#include "../../../include/fxge/fx_ge.h"
#include "../../../include/fxge/fx_freetype.h"
#include "text_int.h"
@@ -1462,7 +1464,7 @@ void CFX_FolderFontInfo::ScanFile(CFX_ByteString& path)
if (GET_TT_LONG(buffer) == 0x74746366) {
FX_DWORD nFaces = GET_TT_LONG(buffer + 8);
- if (nFaces > FX_DWORD_MAX / 4) {
+ if (nFaces > std::numeric_limits<FX_DWORD>::max() / 4) {
FXSYS_fclose(pFile);
return;
}
diff --git a/core/src/fxge/win32/fx_win32_device.cpp b/core/src/fxge/win32/fx_win32_device.cpp
index 24c72fd0ce..3372af103d 100644
--- a/core/src/fxge/win32/fx_win32_device.cpp
+++ b/core/src/fxge/win32/fx_win32_device.cpp
@@ -5,7 +5,7 @@
// Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
#include "../../../include/fxge/fx_ge.h"
-#if _FX_OS_ == _FX_WIN32_DESKTOP_ || _FX_OS_ == _FX_WIN64_
+#if _FX_OS_ == _FX_WIN32_DESKTOP_ || _FX_OS_ == _FX_WIN64_DESKTOP_
#include "../../../include/fxge/fx_ge_win32.h"
#include <crtdbg.h>
#include "../agg/include/fxfx_agg_clip_liang_barsky.h"
@@ -16,7 +16,7 @@
#include "../agg/include/fx_agg_driver.h"
#include "../../../include/fxge/fx_freetype.h"
#include "../../../include/fxcodec/fx_codec.h"
-class CWin32FontInfo FX_FINAL : public IFX_SystemFontInfo
+class CWin32FontInfo final : public IFX_SystemFontInfo
{
public:
CWin32FontInfo();
diff --git a/core/src/fxge/win32/fx_win32_dib.cpp b/core/src/fxge/win32/fx_win32_dib.cpp
index 40fb511a5f..0c6a7e1068 100644
--- a/core/src/fxge/win32/fx_win32_dib.cpp
+++ b/core/src/fxge/win32/fx_win32_dib.cpp
@@ -5,7 +5,7 @@
// Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
#include "../../../include/fxge/fx_ge.h"
-#if _FX_OS_ == _FX_WIN32_DESKTOP_ || _FX_OS_ == _FX_WIN64_
+#if _FX_OS_ == _FX_WIN32_DESKTOP_ || _FX_OS_ == _FX_WIN64_DESKTOP_
#include <windows.h>
#include "../../../include/fxge/fx_ge_win32.h"
#include "win32_int.h"
diff --git a/core/src/fxge/win32/fx_win32_dwrite.cpp b/core/src/fxge/win32/fx_win32_dwrite.cpp
index 1ad4f8c457..022325b5ac 100644
--- a/core/src/fxge/win32/fx_win32_dwrite.cpp
+++ b/core/src/fxge/win32/fx_win32_dwrite.cpp
@@ -5,7 +5,7 @@
// Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
#include "../../../include/fxge/fx_ge.h"
-#if _FX_OS_ == _FX_WIN32_DESKTOP_ || _FX_OS_ == _FX_WIN64_
+#if _FX_OS_ == _FX_WIN32_DESKTOP_ || _FX_OS_ == _FX_WIN64_DESKTOP_
#include "../../../include/fxge/fx_ge_win32.h"
#include "dwrite_int.h"
#include <dwrite.h>
@@ -26,7 +26,7 @@ inline InterfaceType* SafeAcquire(InterfaceType* newObject)
}
return newObject;
}
-class CDwFontFileStream FX_FINAL : public IDWriteFontFileStream
+class CDwFontFileStream final : public IDWriteFontFileStream
{
public:
explicit CDwFontFileStream(void const* fontFileReferenceKey, UINT32 fontFileReferenceKeySize);
@@ -46,7 +46,7 @@ private:
void const* resourcePtr_;
DWORD resourceSize_;
};
-class CDwFontFileLoader FX_FINAL : public IDWriteFontFileLoader
+class CDwFontFileLoader final : public IDWriteFontFileLoader
{
public:
virtual HRESULT STDMETHODCALLTYPE QueryInterface(REFIID iid, void** ppvObject);
diff --git a/core/src/fxge/win32/fx_win32_gdipext.cpp b/core/src/fxge/win32/fx_win32_gdipext.cpp
index 77d18fc5b2..d2aafe09d5 100644
--- a/core/src/fxge/win32/fx_win32_gdipext.cpp
+++ b/core/src/fxge/win32/fx_win32_gdipext.cpp
@@ -5,7 +5,7 @@
// Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
#include "../../../include/fxge/fx_ge.h"
-#if _FX_OS_ == _FX_WIN32_DESKTOP_ || _FX_OS_ == _FX_WIN64_
+#if _FX_OS_ == _FX_WIN32_DESKTOP_ || _FX_OS_ == _FX_WIN64_DESKTOP_
#include <windows.h>
#include <algorithm>
namespace Gdiplus {
@@ -998,7 +998,7 @@ BOOL CGdiplusExt::DrawPath(HDC hDC, const CFX_PathData* pPathData,
CallFunc(GdipDeleteGraphics)(pGraphics);
return TRUE;
}
-class GpStream FX_FINAL : public IStream
+class GpStream final : public IStream
{
LONG m_RefCount;
int m_ReadPos;
diff --git a/core/src/fxge/win32/fx_win32_print.cpp b/core/src/fxge/win32/fx_win32_print.cpp
index c9beefe20b..149df5058c 100644
--- a/core/src/fxge/win32/fx_win32_print.cpp
+++ b/core/src/fxge/win32/fx_win32_print.cpp
@@ -5,7 +5,7 @@
// Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
#include "../../../include/fxge/fx_ge.h"
-#if _FX_OS_ == _FX_WIN32_DESKTOP_ || _FX_OS_ == _FX_WIN64_
+#if _FX_OS_ == _FX_WIN32_DESKTOP_ || _FX_OS_ == _FX_WIN64_DESKTOP_
#include <windows.h>
#include "../../../include/fxge/fx_ge_win32.h"
#include "win32_int.h"