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

Unified Diff: xfa/fxfa/app/xfa_ffnotify.cpp

Issue 2166433002: Cleanup CXFA_Document (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Created 4 years, 5 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 | « no previous file | xfa/fxfa/parser/xfa_document.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: xfa/fxfa/app/xfa_ffnotify.cpp
diff --git a/xfa/fxfa/app/xfa_ffnotify.cpp b/xfa/fxfa/app/xfa_ffnotify.cpp
index be8268a9d47847aec2944011e802d8426ad6af37..09003f023cfc147e248bc121d00babbf33eadc82 100644
--- a/xfa/fxfa/app/xfa_ffnotify.cpp
+++ b/xfa/fxfa/app/xfa_ffnotify.cpp
@@ -174,20 +174,19 @@ void CXFA_FFNotify::StartFieldDrawLayout(CXFA_Node* pItem,
FX_FLOAT& fCalcWidth,
FX_FLOAT& fCalcHeight) {
CXFA_WidgetAcc* pAcc = static_cast<CXFA_WidgetAcc*>(pItem->GetWidgetData());
- if (!pAcc) {
+ if (!pAcc)
return;
- }
+
pAcc->StartWidgetLayout(fCalcWidth, fCalcHeight);
}
+
FX_BOOL CXFA_FFNotify::FindSplitPos(CXFA_Node* pItem,
int32_t iBlockIndex,
FX_FLOAT& fCalcHeightPos) {
CXFA_WidgetAcc* pAcc = static_cast<CXFA_WidgetAcc*>(pItem->GetWidgetData());
- if (!pAcc) {
- return FALSE;
- }
- return (XFA_LAYOUTRESULT)pAcc->FindSplitPos(iBlockIndex, fCalcHeightPos);
dsinclair 2016/07/19 15:20:13 I have no idea why this was casting to an XFA_LAYO
+ return pAcc && pAcc->FindSplitPos(iBlockIndex, fCalcHeightPos);
}
+
FX_BOOL CXFA_FFNotify::RunScript(CXFA_Node* pScript, CXFA_Node* pFormItem) {
FX_BOOL bRet = FALSE;
CXFA_FFDocView* pDocView = m_pDoc->GetDocView();
« no previous file with comments | « no previous file | xfa/fxfa/parser/xfa_document.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698