summaryrefslogtreecommitdiff
path: root/xfa/fxfa/app/xfa_ffsignature.cpp
diff options
context:
space:
mode:
authorDan Sinclair <dsinclair@chromium.org>2017-02-21 14:27:59 -0500
committerChromium commit bot <commit-bot@chromium.org>2017-02-21 20:44:29 +0000
commitb45ea1fce52d93615470bab8b671cba5907fb01e (patch)
tree15153c437a253f73b3f5bb154a294ace77fe2c6d /xfa/fxfa/app/xfa_ffsignature.cpp
parent37a35df8c878d6e21a62ce0dfd2d480997d9e86c (diff)
downloadpdfium-b45ea1fce52d93615470bab8b671cba5907fb01e.tar.xz
Convert CFWL messages to use CFX_PointF
This Cl updates the various CFWL_Message classes to take CFX_PointF instead of x,y values. Change-Id: I5d9d01d68be64fc9e69c04574994c01286ad24e1 Reviewed-on: https://pdfium-review.googlesource.com/2811 Commit-Queue: dsinclair <dsinclair@chromium.org> Reviewed-by: Tom Sepez <tsepez@chromium.org>
Diffstat (limited to 'xfa/fxfa/app/xfa_ffsignature.cpp')
-rw-r--r--xfa/fxfa/app/xfa_ffsignature.cpp49
1 files changed, 27 insertions, 22 deletions
diff --git a/xfa/fxfa/app/xfa_ffsignature.cpp b/xfa/fxfa/app/xfa_ffsignature.cpp
index 53f693d1ba..bf2bba3adf 100644
--- a/xfa/fxfa/app/xfa_ffsignature.cpp
+++ b/xfa/fxfa/app/xfa_ffsignature.cpp
@@ -41,69 +41,74 @@ void CXFA_FFSignature::RenderWidget(CFX_Graphics* pGS,
bool CXFA_FFSignature::OnMouseEnter() {
return false;
}
+
bool CXFA_FFSignature::OnMouseExit() {
return false;
}
+
bool CXFA_FFSignature::OnLButtonDown(uint32_t dwFlags,
- FX_FLOAT fx,
- FX_FLOAT fy) {
+ const CFX_PointF& point) {
return false;
}
-bool CXFA_FFSignature::OnLButtonUp(uint32_t dwFlags, FX_FLOAT fx, FX_FLOAT fy) {
+
+bool CXFA_FFSignature::OnLButtonUp(uint32_t dwFlags, const CFX_PointF& point) {
return false;
}
+
bool CXFA_FFSignature::OnLButtonDblClk(uint32_t dwFlags,
- FX_FLOAT fx,
- FX_FLOAT fy) {
+ const CFX_PointF& point) {
return false;
}
-bool CXFA_FFSignature::OnMouseMove(uint32_t dwFlags, FX_FLOAT fx, FX_FLOAT fy) {
+
+bool CXFA_FFSignature::OnMouseMove(uint32_t dwFlags, const CFX_PointF& point) {
return false;
}
+
bool CXFA_FFSignature::OnMouseWheel(uint32_t dwFlags,
int16_t zDelta,
- FX_FLOAT fx,
- FX_FLOAT fy) {
+ const CFX_PointF& point) {
return false;
}
+
bool CXFA_FFSignature::OnRButtonDown(uint32_t dwFlags,
- FX_FLOAT fx,
- FX_FLOAT fy) {
+ const CFX_PointF& point) {
return false;
}
-bool CXFA_FFSignature::OnRButtonUp(uint32_t dwFlags, FX_FLOAT fx, FX_FLOAT fy) {
+
+bool CXFA_FFSignature::OnRButtonUp(uint32_t dwFlags, const CFX_PointF& point) {
return false;
}
+
bool CXFA_FFSignature::OnRButtonDblClk(uint32_t dwFlags,
- FX_FLOAT fx,
- FX_FLOAT fy) {
+ const CFX_PointF& point) {
return false;
}
+
bool CXFA_FFSignature::OnKeyDown(uint32_t dwKeyCode, uint32_t dwFlags) {
return false;
}
+
bool CXFA_FFSignature::OnKeyUp(uint32_t dwKeyCode, uint32_t dwFlags) {
return false;
}
+
bool CXFA_FFSignature::OnChar(uint32_t dwChar, uint32_t dwFlags) {
return false;
}
-FWL_WidgetHit CXFA_FFSignature::OnHitTest(FX_FLOAT fx, FX_FLOAT fy) {
- if (m_pNormalWidget) {
- FX_FLOAT ffx = fx, ffy = fy;
- FWLToClient(ffx, ffy);
- if (m_pNormalWidget->HitTest(ffx, ffy) != FWL_WidgetHit::Unknown)
- return FWL_WidgetHit::Client;
+FWL_WidgetHit CXFA_FFSignature::OnHitTest(const CFX_PointF& point) {
+ if (m_pNormalWidget &&
+ m_pNormalWidget->HitTest(FWLToClient(point)) != FWL_WidgetHit::Unknown) {
+ return FWL_WidgetHit::Client;
}
- if (!GetRectWithoutRotate().Contains(fx, fy))
+ if (!GetRectWithoutRotate().Contains(point))
return FWL_WidgetHit::Unknown;
- if (m_rtCaption.Contains(fx, fy))
+ if (m_rtCaption.Contains(point))
return FWL_WidgetHit::Titlebar;
return FWL_WidgetHit::Client;
}
-bool CXFA_FFSignature::OnSetCursor(FX_FLOAT fx, FX_FLOAT fy) {
+bool CXFA_FFSignature::OnSetCursor(const CFX_PointF& point) {
return false;
}