summaryrefslogtreecommitdiff
path: root/fpdfsdk/cpdfsdk_formfillenvironment.cpp
diff options
context:
space:
mode:
authorLei Zhang <thestig@chromium.org>2017-05-19 19:25:16 -0700
committerChromium commit bot <commit-bot@chromium.org>2017-05-22 18:28:21 +0000
commit671630e52cda1abb5b1da71f366211cc3c95482f (patch)
tree701f3f8af350b0065415876ecfc86c4a300d0078 /fpdfsdk/cpdfsdk_formfillenvironment.cpp
parent6c8ed646d1fcb8cce5a01c843c5149d989e6d5f0 (diff)
downloadpdfium-671630e52cda1abb5b1da71f366211cc3c95482f.tar.xz
Use less opaque types in CPDFSDK_FormFillEnvironment.
Fix type mismatches. Change-Id: Id475f927d0919f60a84f17bd9545ec67d569ff64 Reviewed-on: https://pdfium-review.googlesource.com/5740 Reviewed-by: Tom Sepez <tsepez@chromium.org> Commit-Queue: Lei Zhang <thestig@chromium.org>
Diffstat (limited to 'fpdfsdk/cpdfsdk_formfillenvironment.cpp')
-rw-r--r--fpdfsdk/cpdfsdk_formfillenvironment.cpp22
1 files changed, 12 insertions, 10 deletions
diff --git a/fpdfsdk/cpdfsdk_formfillenvironment.cpp b/fpdfsdk/cpdfsdk_formfillenvironment.cpp
index cb5509681a..8c5025ed88 100644
--- a/fpdfsdk/cpdfsdk_formfillenvironment.cpp
+++ b/fpdfsdk/cpdfsdk_formfillenvironment.cpp
@@ -233,7 +233,7 @@ CPDFSDK_FormFillEnvironment::GetInteractiveFormFiller() {
return m_pFormFiller.get();
}
-void CPDFSDK_FormFillEnvironment::Invalidate(FPDF_PAGE page,
+void CPDFSDK_FormFillEnvironment::Invalidate(UnderlyingPageType* page,
const FX_RECT& rect) {
if (m_pInfo && m_pInfo->FFI_Invalidate) {
m_pInfo->FFI_Invalidate(m_pInfo, page, rect.left, rect.top, rect.right,
@@ -242,7 +242,7 @@ void CPDFSDK_FormFillEnvironment::Invalidate(FPDF_PAGE page,
}
void CPDFSDK_FormFillEnvironment::OutputSelectedRect(
- FPDF_PAGE page,
+ UnderlyingPageType* page,
const CFX_FloatRect& rect) {
if (m_pInfo && m_pInfo->FFI_OutputSelectedRect) {
m_pInfo->FFI_OutputSelectedRect(m_pInfo, page, rect.left, rect.top,
@@ -301,14 +301,15 @@ bool CPDFSDK_FormFillEnvironment::IsALTKeyDown(uint32_t nFlag) const {
return (nFlag & FWL_EVENTFLAG_AltKey) != 0;
}
-FPDF_PAGE CPDFSDK_FormFillEnvironment::GetPage(FPDF_DOCUMENT document,
+FPDF_PAGE CPDFSDK_FormFillEnvironment::GetPage(UnderlyingDocumentType* document,
int nPageIndex) {
if (m_pInfo && m_pInfo->FFI_GetPage)
return m_pInfo->FFI_GetPage(m_pInfo, document, nPageIndex);
return nullptr;
}
-FPDF_PAGE CPDFSDK_FormFillEnvironment::GetCurrentPage(FPDF_DOCUMENT document) {
+FPDF_PAGE CPDFSDK_FormFillEnvironment::GetCurrentPage(
+ UnderlyingDocumentType* document) {
if (m_pInfo && m_pInfo->FFI_GetCurrentPage)
return m_pInfo->FFI_GetCurrentPage(m_pInfo, document);
return nullptr;
@@ -343,7 +344,7 @@ void CPDFSDK_FormFillEnvironment::DoGoToAction(int nPageIndex,
}
#ifdef PDF_ENABLE_XFA
-void CPDFSDK_FormFillEnvironment::DisplayCaret(FPDF_PAGE page,
+void CPDFSDK_FormFillEnvironment::DisplayCaret(CPDFXFA_Page* page,
FPDF_BOOL bVisible,
double left,
double top,
@@ -355,13 +356,14 @@ void CPDFSDK_FormFillEnvironment::DisplayCaret(FPDF_PAGE page,
}
}
-int CPDFSDK_FormFillEnvironment::GetCurrentPageIndex(FPDF_DOCUMENT document) {
+int CPDFSDK_FormFillEnvironment::GetCurrentPageIndex(
+ CPDFXFA_Context* document) {
if (!m_pInfo || !m_pInfo->FFI_GetCurrentPageIndex)
return -1;
return m_pInfo->FFI_GetCurrentPageIndex(m_pInfo, document);
}
-void CPDFSDK_FormFillEnvironment::SetCurrentPage(FPDF_DOCUMENT document,
+void CPDFSDK_FormFillEnvironment::SetCurrentPage(CPDFXFA_Context* document,
int iCurPage) {
if (m_pInfo && m_pInfo->FFI_SetCurrentPage)
m_pInfo->FFI_SetCurrentPage(m_pInfo, document, iCurPage);
@@ -385,7 +387,7 @@ CFX_WideString CPDFSDK_FormFillEnvironment::GetPlatform() {
nActualLen / sizeof(uint16_t));
}
-void CPDFSDK_FormFillEnvironment::GotoURL(FPDF_DOCUMENT document,
+void CPDFSDK_FormFillEnvironment::GotoURL(CPDFXFA_Context* document,
const CFX_WideStringC& wsURL) {
if (!m_pInfo || !m_pInfo->FFI_GotoURL)
return;
@@ -396,7 +398,7 @@ void CPDFSDK_FormFillEnvironment::GotoURL(FPDF_DOCUMENT document,
bsTo.ReleaseBuffer();
}
-void CPDFSDK_FormFillEnvironment::GetPageViewRect(FPDF_PAGE page,
+void CPDFSDK_FormFillEnvironment::GetPageViewRect(CPDFXFA_Page* page,
FS_RECTF& dstRect) {
if (!m_pInfo || !m_pInfo->FFI_GetPageViewRect)
return;
@@ -413,7 +415,7 @@ void CPDFSDK_FormFillEnvironment::GetPageViewRect(FPDF_PAGE page,
dstRect.right = static_cast<float>(right);
}
-bool CPDFSDK_FormFillEnvironment::PopupMenu(FPDF_PAGE page,
+bool CPDFSDK_FormFillEnvironment::PopupMenu(CPDFXFA_Page* page,
FPDF_WIDGET hWidget,
int menuFlag,
CFX_PointF pt) {