summaryrefslogtreecommitdiff
path: root/xfa/fxfa/cxfa_fftext.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'xfa/fxfa/cxfa_fftext.cpp')
-rw-r--r--xfa/fxfa/cxfa_fftext.cpp12
1 files changed, 10 insertions, 2 deletions
diff --git a/xfa/fxfa/cxfa_fftext.cpp b/xfa/fxfa/cxfa_fftext.cpp
index a446993520..5d6152e7a4 100644
--- a/xfa/fxfa/cxfa_fftext.cpp
+++ b/xfa/fxfa/cxfa_fftext.cpp
@@ -99,7 +99,12 @@ bool CXFA_FFText::PerformLayout() {
return true;
}
-bool CXFA_FFText::OnLButtonDown(uint32_t dwFlags, const CFX_PointF& point) {
+bool CXFA_FFText::AcceptsFocusOnButtonDown(uint32_t dwFlags,
+ const CFX_PointF& point,
+ FWL_MouseCommand command) {
+ if (command != FWL_MouseCommand::LeftButtonDown)
+ return false;
+
if (!GetRectWithoutRotate().Contains(point))
return false;
@@ -107,10 +112,13 @@ bool CXFA_FFText::OnLButtonDown(uint32_t dwFlags, const CFX_PointF& point) {
if (!wsURLContent)
return false;
- SetButtonDown(true);
return true;
}
+void CXFA_FFText::OnLButtonDown(uint32_t dwFlags, const CFX_PointF& point) {
+ SetButtonDown(true);
+}
+
bool CXFA_FFText::OnMouseMove(uint32_t dwFlags, const CFX_PointF& point) {
return GetRectWithoutRotate().Contains(point) && !!GetLinkURLAtPoint(point);
}