longpress location info bug fix

Signed-off-by: zhouchaobo <zhouchaobo@huawei.com>
Change-Id: I0fe537b09226568a7f6a10bc550e7f4d67ee8e63
This commit is contained in:
zhouchaobo 2024-07-15 10:32:01 +08:00
parent 5c34a572d8
commit ecd118cbd0

View File

@ -356,6 +356,9 @@ void LongPressRecognizer::SendCallbackMsg(
info.SetDeviceId(deviceId_);
info.SetTargetDisplayId(lastTouchEvent_.targetDisplayId);
info.SetGlobalPoint(globalPoint_);
info.SetScreenLocation(lastTouchEvent_.GetScreenOffset());
info.SetGlobalLocation(lastTouchEvent_.GetOffset())
.SetLocalLocation(lastTouchEvent_.GetOffset() - coordinateOffset_);
info.SetTarget(GetEventTarget().value_or(EventTarget()));
info.SetForce(lastTouchEvent_.force);
if (lastTouchEvent_.tiltX.has_value()) {