diff options
author | Lei Zhang <thestig@chromium.org> | 2017-05-10 14:00:53 -0700 |
---|---|---|
committer | Chromium commit bot <commit-bot@chromium.org> | 2017-05-10 21:08:04 +0000 |
commit | 0a0892626d24ce82e7026c32c71b1de036d4bbe1 (patch) | |
tree | 470bca7e1c5b27c967d246706d21018fd4d2d1f2 /core/fpdfapi/page/cpdf_streamcontentparser.cpp | |
parent | 6f62ccd50ff85ba6a60ddf47993745739854cd8f (diff) | |
download | pdfium-0a0892626d24ce82e7026c32c71b1de036d4bbe1.tar.xz |
Replace operator bool with HasRef() in classes with a CFX_SharedCopyOnWrite member.
Change-Id: I51e30d298e87b9ae0d5aca83b2f1d6787efce70a
Reviewed-on: https://pdfium-review.googlesource.com/5290
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Reviewed-by: Nicolás Peña <npm@chromium.org>
Diffstat (limited to 'core/fpdfapi/page/cpdf_streamcontentparser.cpp')
-rw-r--r-- | core/fpdfapi/page/cpdf_streamcontentparser.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/core/fpdfapi/page/cpdf_streamcontentparser.cpp b/core/fpdfapi/page/cpdf_streamcontentparser.cpp index 3e6e75a53e..099ddf6b05 100644 --- a/core/fpdfapi/page/cpdf_streamcontentparser.cpp +++ b/core/fpdfapi/page/cpdf_streamcontentparser.cpp @@ -838,7 +838,7 @@ void CPDF_StreamContentParser::Handle_MarkPlace_Dictionary() {} void CPDF_StreamContentParser::Handle_EndImage() {} void CPDF_StreamContentParser::Handle_EndMarkedContent() { - if (m_CurContentMark) + if (m_CurContentMark.HasRef()) m_CurContentMark.DeleteLastMark(); } @@ -1121,7 +1121,7 @@ void CPDF_StreamContentParser::Handle_ShadeFill() { pObj->m_Matrix = m_pCurStates->m_CTM; pObj->m_Matrix.Concat(m_mtContentToUser); CFX_FloatRect bbox = - pObj->m_ClipPath ? pObj->m_ClipPath.GetClipBox() : m_BBox; + pObj->m_ClipPath.HasRef() ? pObj->m_ClipPath.GetClipBox() : m_BBox; if (pShading->IsMeshShading()) bbox.Intersect(GetShadingBBox(pShading, pObj->m_Matrix)); pObj->m_Left = bbox.left; |