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

Unified Diff: fpdfsdk/src/fsdk_mgr.cpp

Issue 1474663004: XFA: more underlying type changes to match master (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@xfa
Patch Set: Created 5 years, 1 month 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/src/fpdfformfill.cpp ('K') | « fpdfsdk/src/fsdk_baseform.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: fpdfsdk/src/fsdk_mgr.cpp
diff --git a/fpdfsdk/src/fsdk_mgr.cpp b/fpdfsdk/src/fsdk_mgr.cpp
index 69432a4af10d10b5c3f7e5f3416455d1173d0344..b05fd128a1277a83ff569bdecf6c21770b92c065 100644
--- a/fpdfsdk/src/fsdk_mgr.cpp
+++ b/fpdfsdk/src/fsdk_mgr.cpp
@@ -530,16 +530,17 @@ FX_BOOL CPDFSDK_Document::SetFocusAnnot(CPDFSDK_Annot* pAnnot, FX_UINT nFlag) {
if (m_pFocusAnnot == pAnnot)
return TRUE;
- CPDFSDK_Annot* pLastFocusAnnot = m_pFocusAnnot;
-
if (m_pFocusAnnot) {
if (!KillFocusAnnot(nFlag))
return FALSE;
}
- CPDFSDK_PageView* pPageView = NULL;
- if (pAnnot)
- pPageView = pAnnot->GetPageView();
- if (pAnnot && pPageView->IsValid()) {
+
+ if (!pAnnot)
+ return FALSE;
+
+ CPDFSDK_Annot* pLastFocusAnnot = m_pFocusAnnot;
+ CPDFSDK_PageView* pPageView = pAnnot->GetPageView();
+ if (pPageView && pPageView->IsValid()) {
CPDFSDK_AnnotHandlerMgr* pAnnotHandler = m_pEnv->GetAnnotHandlerMgr();
if (!m_pFocusAnnot) {
if (!pAnnotHandler->Annot_OnChangeFocus(pAnnot, pLastFocusAnnot))
@@ -589,8 +590,7 @@ void CPDFSDK_Document::OnCloseDocument() {
}
FX_BOOL CPDFSDK_Document::GetPermissions(int nFlag) {
- FX_DWORD dwPermissions = m_pDoc->GetPDFDoc()->GetUserPermissions();
- return dwPermissions & nFlag;
+ return GetPDFDocument()->GetUserPermissions() & nFlag;
}
IJS_Runtime* CPDFSDK_Document::GetJsRuntime() {
@@ -604,7 +604,7 @@ CFX_WideString CPDFSDK_Document::GetPath() {
}
CPDFSDK_PageView::CPDFSDK_PageView(CPDFSDK_Document* pSDKDoc,
- CPDFXFA_Page* page)
+ UnderlyingPageType* page)
: m_page(page),
m_pSDKDoc(pSDKDoc),
m_CaptureWidget(nullptr),
« fpdfsdk/src/fpdfformfill.cpp ('K') | « fpdfsdk/src/fsdk_baseform.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698