Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(113)

Unified Diff: fpdfsdk/formfiller/cffl_interactiveformfiller.cpp

Issue 2399213002: Remove remaining CPDFSDK_Document references (Closed)
Patch Set: Rebase to master Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « fpdfsdk/formfiller/cffl_formfiller.cpp ('k') | fpdfsdk/javascript/Document.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: fpdfsdk/formfiller/cffl_interactiveformfiller.cpp
diff --git a/fpdfsdk/formfiller/cffl_interactiveformfiller.cpp b/fpdfsdk/formfiller/cffl_interactiveformfiller.cpp
index c62de9bfb5cb6e0fb7980751f14c3d1e19023dc9..27ad4faeb68e26ac169eeec10b8b4a6b638df4be 100644
--- a/fpdfsdk/formfiller/cffl_interactiveformfiller.cpp
+++ b/fpdfsdk/formfiller/cffl_interactiveformfiller.cpp
@@ -67,8 +67,7 @@ void CFFL_InteractiveFormFiller::OnDraw(CPDFSDK_PageView* pPageView,
pFormFiller->OnDraw(pPageView, pAnnot, pDevice, pUser2Device);
pAnnot->GetPDFPage();
- CPDFSDK_Document* pDocument = m_pEnv->GetSDKDocument();
- if (pDocument->GetFocusAnnot() == pAnnot) {
+ if (m_pEnv->GetSDKDocument()->GetFocusAnnot() == pAnnot) {
CFX_FloatRect rcFocus = pFormFiller->GetFocusBox(pPageView);
if (!rcFocus.IsEmpty()) {
CFX_PathData path;
@@ -239,7 +238,6 @@ FX_BOOL CFFL_InteractiveFormFiller::OnLButtonUp(
const CFX_FloatPoint& point) {
ASSERT((*pAnnot)->GetPDFAnnot()->GetSubtype() == CPDF_Annot::Subtype::WIDGET);
CPDFSDK_Widget* pWidget = static_cast<CPDFSDK_Widget*>(pAnnot->Get());
- CPDFSDK_Document* pDocument = m_pEnv->GetSDKDocument();
switch (pWidget->GetFieldType()) {
case FIELDTYPE_PUSHBUTTON:
@@ -247,10 +245,10 @@ FX_BOOL CFFL_InteractiveFormFiller::OnLButtonUp(
case FIELDTYPE_RADIOBUTTON:
if (GetViewBBox(pPageView, pAnnot->Get())
.Contains((int)point.x, (int)point.y))
- pDocument->SetFocusAnnot(pAnnot);
+ m_pEnv->GetSDKDocument()->SetFocusAnnot(pAnnot);
break;
default:
- pDocument->SetFocusAnnot(pAnnot);
+ m_pEnv->GetSDKDocument()->SetFocusAnnot(pAnnot);
break;
}
@@ -258,7 +256,7 @@ FX_BOOL CFFL_InteractiveFormFiller::OnLButtonUp(
if (CFFL_FormFiller* pFormFiller = GetFormFiller(pAnnot->Get(), FALSE))
bRet = pFormFiller->OnLButtonUp(pPageView, pAnnot->Get(), nFlags, point);
- if (pDocument->GetFocusAnnot() == pAnnot->Get()) {
+ if (m_pEnv->GetSDKDocument()->GetFocusAnnot() == pAnnot->Get()) {
FX_BOOL bExit = FALSE;
FX_BOOL bReset = FALSE;
OnButtonUp(pAnnot, pPageView, bReset, bExit, nFlags);
« no previous file with comments | « fpdfsdk/formfiller/cffl_formfiller.cpp ('k') | fpdfsdk/javascript/Document.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698