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

Unified Diff: fpdfsdk/javascript/Field.cpp

Issue 2397723005: Convert CPDFSDK_InterForm to take a CPDFSDK_FormFillEnvironment (Closed)
Patch Set: 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
« fpdfsdk/cpdfsdk_interform.cpp ('K') | « fpdfsdk/cpdfsdk_widget.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: fpdfsdk/javascript/Field.cpp
diff --git a/fpdfsdk/javascript/Field.cpp b/fpdfsdk/javascript/Field.cpp
index fa2ac70aa515fee47b79a0acfd0b85b241c5f955..6d11560a17b1b21779dbd662dd0d23178657d5e0 100644
--- a/fpdfsdk/javascript/Field.cpp
+++ b/fpdfsdk/javascript/Field.cpp
@@ -296,8 +296,10 @@ void Field::UpdateFormField(CPDFSDK_Document* pDocument,
pInterForm->GetWidgets(pFormField, &widgets);
for (CPDFSDK_Widget* pWidget : widgets) {
- CPDFSDK_Document* pDoc = pWidget->GetInterForm()->GetDocument();
- pDoc->UpdateAllViews(nullptr, pWidget);
+ pWidget->GetInterForm()
+ ->GetFormFillEnv()
+ ->GetSDKDocument()
Tom Sepez 2016/10/06 18:42:06 is the document invariant across the all widgets?
dsinclair 2016/10/06 19:21:23 a document has a single InterForm, but I haven't d
+ ->UpdateAllViews(nullptr, pWidget);
}
}
@@ -330,8 +332,8 @@ void Field::UpdateFormControl(CPDFSDK_Document* pDocument,
if (bRefresh) {
CPDFSDK_InterForm* pInterForm = pWidget->GetInterForm();
- CPDFSDK_Document* pDoc = pInterForm->GetDocument();
- pDoc->UpdateAllViews(nullptr, pWidget);
+ pInterForm->GetFormFillEnv()->GetSDKDocument()->UpdateAllViews(nullptr,
+ pWidget);
}
}
« fpdfsdk/cpdfsdk_interform.cpp ('K') | « fpdfsdk/cpdfsdk_widget.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698