summaryrefslogtreecommitdiff
path: root/fpdfsdk/src/fsdk_annothandler.cpp
diff options
context:
space:
mode:
authorDan Sinclair <dsinclair@chromium.org>2015-11-04 13:49:51 -0500
committerDan Sinclair <dsinclair@chromium.org>2015-11-04 13:49:51 -0500
commit110650e68e519e8cf14fe1119b77cf3309ed2d0b (patch)
tree1f909326f5de37a2c64a47d404f5158d9c898513 /fpdfsdk/src/fsdk_annothandler.cpp
parentd3def7e54daef743ab0efbadda4531c64ffd1fc3 (diff)
downloadpdfium-110650e68e519e8cf14fe1119b77cf3309ed2d0b.tar.xz
Cleanup after syncing CPDFSDK_BAAnnot
This cleans up various things after syncing BAAnnot to master. R=thestig@chromium.org Review URL: https://codereview.chromium.org/1418043007 .
Diffstat (limited to 'fpdfsdk/src/fsdk_annothandler.cpp')
-rw-r--r--fpdfsdk/src/fsdk_annothandler.cpp11
1 files changed, 5 insertions, 6 deletions
diff --git a/fpdfsdk/src/fsdk_annothandler.cpp b/fpdfsdk/src/fsdk_annothandler.cpp
index d6a2c00bd6..d3d6567ccd 100644
--- a/fpdfsdk/src/fsdk_annothandler.cpp
+++ b/fpdfsdk/src/fsdk_annothandler.cpp
@@ -116,13 +116,13 @@ void CPDFSDK_AnnotHandlerMgr::Annot_OnDraw(CPDFSDK_PageView* pPageView,
CFX_RenderDevice* pDevice,
CPDF_Matrix* pUser2Device,
FX_DWORD dwFlags) {
- ASSERT(pAnnot != NULL);
+ ASSERT(pAnnot);
if (IPDFSDK_AnnotHandler* pAnnotHandler = GetAnnotHandler(pAnnot)) {
pAnnotHandler->OnDraw(pPageView, pAnnot, pDevice, pUser2Device, dwFlags);
} else {
- ((CPDFSDK_BAAnnot*)pAnnot)
- ->DrawAppearance(pDevice, pUser2Device, CPDF_Annot::Normal, NULL);
+ static_cast<CPDFSDK_BAAnnot*>(pAnnot)
+ ->DrawAppearance(pDevice, pUser2Device, CPDF_Annot::Normal, nullptr);
}
}
@@ -381,12 +381,11 @@ void CPDFSDK_BFAnnotHandler::OnDraw(CPDFSDK_PageView* pPageView,
CFX_RenderDevice* pDevice,
CPDF_Matrix* pUser2Device,
FX_DWORD dwFlags) {
- ASSERT(pAnnot != NULL);
CFX_ByteString sSubType = pAnnot->GetSubType();
if (sSubType == BFFT_SIGNATURE) {
- ((CPDFSDK_BAAnnot*)pAnnot)
- ->DrawAppearance(pDevice, pUser2Device, CPDF_Annot::Normal, NULL);
+ static_cast<CPDFSDK_BAAnnot*>(pAnnot)
+ ->DrawAppearance(pDevice, pUser2Device, CPDF_Annot::Normal, nullptr);
} else {
if (m_pFormFiller) {
m_pFormFiller->OnDraw(pPageView, pAnnot, pDevice, pUser2Device, dwFlags);