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

Unified Diff: xfa/fxfa/app/xfa_fftext.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
« no previous file with comments | « xfa/fxfa/app/xfa_fftext.h ('k') | xfa/fxfa/app/xfa_ffwidget.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: xfa/fxfa/app/xfa_fftext.cpp
diff --git a/xfa/fxfa/app/xfa_fftext.cpp b/xfa/fxfa/app/xfa_fftext.cpp
index b529f7e58a84ea57ff18010115993a160e015e74..c5e1cba2a8fb95e14368be09a1425ce1214c409c 100644
--- a/xfa/fxfa/app/xfa_fftext.cpp
+++ b/xfa/fxfa/app/xfa_fftext.cpp
@@ -139,16 +139,14 @@ FX_BOOL CXFA_FFText::OnLButtonUp(uint32_t dwFlags, FX_FLOAT fx, FX_FLOAT fy) {
pDoc->GetDocProvider()->GotoURL(pDoc, CFX_WideStringC(wsURLContent), FALSE);
return TRUE;
}
-uint32_t CXFA_FFText::OnHitTest(FX_FLOAT fx, FX_FLOAT fy) {
+FWL_WidgetHit CXFA_FFText::OnHitTest(FX_FLOAT fx, FX_FLOAT fy) {
CFX_RectF rtBox;
GetRectWithoutRotate(rtBox);
- if (!rtBox.Contains(fx, fy)) {
- return FWL_WGTHITTEST_Unknown;
- }
- if (!GetLinkURLAtPoint(fx, fy)) {
- return FWL_WGTHITTEST_Unknown;
- }
- return FWL_WGTHITTEST_HyperLink;
+ if (!rtBox.Contains(fx, fy))
+ return FWL_WidgetHit::Unknown;
+ if (!GetLinkURLAtPoint(fx, fy))
+ return FWL_WidgetHit::Unknown;
+ return FWL_WidgetHit::HyperLink;
}
const FX_WCHAR* CXFA_FFText::GetLinkURLAtPoint(FX_FLOAT fx, FX_FLOAT fy) {
CXFA_TextLayout* pTextLayout = m_pDataAcc->GetTextLayout();
« no previous file with comments | « xfa/fxfa/app/xfa_fftext.h ('k') | xfa/fxfa/app/xfa_ffwidget.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698