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

Unified Diff: fpdfsdk/fsdk_annothandler.cpp

Issue 1948583002: Remove FWL_WGTHITTEST_* defines in favour of enum class. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Created 4 years, 8 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
Index: fpdfsdk/fsdk_annothandler.cpp
diff --git a/fpdfsdk/fsdk_annothandler.cpp b/fpdfsdk/fsdk_annothandler.cpp
index 24f3d60d4737ab14c15c2e776c7ce7bed0abb403..721270aa1903c354a1760acd0c7369ea5a1059d6 100644
--- a/fpdfsdk/fsdk_annothandler.cpp
+++ b/fpdfsdk/fsdk_annothandler.cpp
@@ -19,6 +19,7 @@
#include "fpdfsdk/fpdfxfa/include/fpdfxfa_doc.h"
#include "fpdfsdk/fpdfxfa/include/fpdfxfa_page.h"
#include "fpdfsdk/fpdfxfa/include/fpdfxfa_util.h"
+#include "xfa/fwl/core/include/fwl_widgethittest.h"
#include "xfa/fxfa/include/xfa_ffwidget.h"
#include "xfa/fxgraphics/include/cfx_graphics.h"
#endif // PDF_ENABLE_XFA
@@ -723,14 +724,6 @@ FX_BOOL CPDFSDK_BFAnnotHandler::HitTest(CPDFSDK_PageView* pPageView,
}
#ifdef PDF_ENABLE_XFA
-#define FWL_WGTHITTEST_Unknown 0
-#define FWL_WGTHITTEST_Client 1 // arrow
-#define FWL_WGTHITTEST_Titlebar 11 // caption
-#define FWL_WGTHITTEST_HScrollBar 15
-#define FWL_WGTHITTEST_VScrollBar 16
-#define FWL_WGTHITTEST_Border 17
-#define FWL_WGTHITTEST_Edit 19
-#define FWL_WGTHITTEST_HyperLink 20
CPDFSDK_XFAAnnotHandler::CPDFSDK_XFAAnnotHandler(CPDFDoc_Environment* pApp)
: m_pApp(pApp) {}
@@ -825,9 +818,9 @@ FX_BOOL CPDFSDK_XFAAnnotHandler::HitTest(CPDFSDK_PageView* pPageView,
if (!pWidgetHandler)
return FALSE;
- uint32_t dwHitTest =
+ FWL_WidgetHitTest dwHitTest =
pWidgetHandler->OnHitTest(pAnnot->GetXFAWidget(), point.x, point.y);
- return (dwHitTest != FWL_WGTHITTEST_Unknown);
+ return (dwHitTest != FWL_WidgetHitTest::Unknown);
Tom Sepez 2016/05/03 18:33:19 nit: overparenthesized.
dsinclair 2016/05/03 19:34:48 Done.
}
void CPDFSDK_XFAAnnotHandler::OnMouseEnter(CPDFSDK_PageView* pPageView,
« no previous file with comments | « fpdfsdk/DEPS ('k') | xfa.gyp » ('j') | xfa/fwl/core/include/fwl_widgethittest.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698