From ff46aaf499edcf153ee2f57c7016587aa96dcfa0 Mon Sep 17 00:00:00 2001 From: Tom Sepez Date: Mon, 27 Jul 2015 11:55:29 -0700 Subject: FX Bool considered harmful, part 3 Try to reland this patch after fixing underlying issues that caused it to be reverted. fx_system.h is the only manual edit. R=thestig@chromium.org Review URL: https://codereview.chromium.org/1258093002 . --- core/include/fpdfapi/fpdf_pageobj.h | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) (limited to 'core/include/fpdfapi/fpdf_pageobj.h') diff --git a/core/include/fpdfapi/fpdf_pageobj.h b/core/include/fpdfapi/fpdf_pageobj.h index 73540a3eb3..c140de6c82 100644 --- a/core/include/fpdfapi/fpdf_pageobj.h +++ b/core/include/fpdfapi/fpdf_pageobj.h @@ -88,7 +88,7 @@ public: m_pObject->AppendRect(left, bottom, right, top); } - FX_BOOL IsRect() const + bool IsRect() const { return m_pObject->IsRect(); } @@ -147,7 +147,7 @@ public: CFX_FloatRect GetClipBox() const; - void AppendPath(CPDF_Path path, int type, FX_BOOL bAutoMerge); + void AppendPath(CPDF_Path path, int type, bool bAutoMerge); void DeletePath(int layer_index); @@ -292,15 +292,15 @@ public: int m_RenderIntent; - FX_BOOL m_StrokeAdjust; + bool m_StrokeAdjust; - FX_BOOL m_AlphaSource; + bool m_AlphaSource; - FX_BOOL m_TextKnockout; + bool m_TextKnockout; - FX_BOOL m_StrokeOP; + bool m_StrokeOP; - FX_BOOL m_FillOP; + bool m_FillOP; int m_OPMode; @@ -325,7 +325,7 @@ public: return m_pObject ? m_pObject->m_BlendType : FXDIB_BLEND_NORMAL; } - int GetAlpha(FX_BOOL bStroke) const + int GetAlpha(bool bStroke) const { return m_pObject ? FXSYS_round((bStroke ? m_pObject->m_StrokeAlpha : m_pObject->m_FillAlpha) * 255) : 255; } @@ -362,7 +362,7 @@ public: return m_pParam; } - inline FX_BOOL HasMCID() const; + inline bool HasMCID() const; inline void SetName(const CFX_ByteString& name) { @@ -402,7 +402,7 @@ public: int GetMCID() const; - void AddMark(const CFX_ByteString& name, CPDF_Dictionary* pDict, FX_BOOL bDictNeedClone); + void AddMark(const CFX_ByteString& name, CPDF_Dictionary* pDict, bool bDictNeedClone); void DeleteLastMark(); private: @@ -418,9 +418,9 @@ public: return m_pObject ? m_pObject->GetMCID() : -1; } - FX_BOOL HasMark(const CFX_ByteStringC& mark) const; + bool HasMark(const CFX_ByteStringC& mark) const; - FX_BOOL LookupMark(const CFX_ByteStringC& mark, CPDF_Dictionary*& pDict) const; + bool LookupMark(const CFX_ByteStringC& mark, CPDF_Dictionary*& pDict) const; }; #define PDFPAGE_TEXT 1 @@ -461,7 +461,7 @@ public: void RemoveClipPath(); - void AppendClipPath(CPDF_Path path, int type, FX_BOOL bAutoMerge); + void AppendClipPath(CPDF_Path path, int type, bool bAutoMerge); void CopyClipPath(CPDF_PageObject* pObj); @@ -629,7 +629,7 @@ public: int m_FillType; - FX_BOOL m_bStroke; + bool m_bStroke; CFX_AffineMatrix m_Matrix; -- cgit v1.2.3