Use scaled x,y for touch hover

This commit is contained in:
Duy Tran Khanh 2021-10-12 11:13:56 +07:00 committed by GitHub
parent f1e4f6ea4c
commit f30b4a23e0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -445,7 +445,7 @@ public class BaseMainActivity extends LoggableActivity {
scrollInitialX = (int)mouse_x; scrollInitialX = (int)mouse_x;
scrollInitialY = (int)mouse_y; scrollInitialY = (int)mouse_y;
} else if (!CallbackBridge.isGrabbing() && e.getPointerCount() == 1) { //Touch hover } else if (!CallbackBridge.isGrabbing() && e.getPointerCount() == 1) { //Touch hover
CallbackBridge.sendCursorPos(e.getX(), e.getY()); CallbackBridge.sendCursorPos(mouse_x, mouse_y);
prevX = e.getX(); prevX = e.getX();
prevY = e.getY(); prevY = e.getY();
} else if (!isTouchInHotbar) { } else if (!isTouchInHotbar) {