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

Unified Diff: fpdfsdk/src/fsdk_mgr.cpp

Issue 1472363003: XFA: More underlying types (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@xfa
Patch Set: Missing include 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
« no previous file with comments | « fpdfsdk/src/fpdfview.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 27cfe514c8d463671eba1a6eac4dd37a0a3c1eb0..ed2ac1a971cb16b3efb06dec266f2d42e2547b02 100644
--- a/fpdfsdk/src/fsdk_mgr.cpp
+++ b/fpdfsdk/src/fsdk_mgr.cpp
@@ -638,7 +638,6 @@ void CPDFSDK_PageView::PageView_OnDraw(CFX_RenderDevice* pDevice,
m_curMatrix = *pUser2Device;
CPDFDoc_Environment* pEnv = m_pSDKDoc->GetEnv();
CPDFXFA_Page* pPage = GetPDFXFAPage();
-
if (pPage == NULL)
return;
@@ -718,8 +717,9 @@ CPDFSDK_Annot* CPDFSDK_PageView::GetFXWidgetAtPoint(FX_FLOAT pageX,
CPDFSDK_AnnotHandlerMgr* pAnnotMgr = pEnv->GetAnnotHandlerMgr();
CPDFSDK_AnnotIterator annotIterator(this, false);
while (CPDFSDK_Annot* pSDKAnnot = annotIterator.Next()) {
- if (pSDKAnnot->GetType() == "Widget" ||
- pSDKAnnot->GetType() == FSDK_XFAWIDGET_TYPENAME) {
+ bool bHitTest = pSDKAnnot->GetType() == "Widget";
+ bHitTest = bHitTest || pSDKAnnot->GetType() == FSDK_XFAWIDGET_TYPENAME;
+ if (bHitTest) {
pAnnotMgr->Annot_OnGetViewBBox(this, pSDKAnnot);
CPDF_Point point(pageX, pageY);
if (pAnnotMgr->Annot_OnHitTest(this, pSDKAnnot, point))
@@ -815,7 +815,6 @@ CPDF_Page* CPDFSDK_PageView::GetPDFPage() {
if (m_page) {
return m_page->GetPDFPage();
}
-
return NULL;
}
« no previous file with comments | « fpdfsdk/src/fpdfview.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698