Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make Force Touch inputs detects rejection zone #168

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions VoodooRMI/Functions/Input/RMITrackpadFunction.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,8 @@ void RMITrackpadFunction::handleReport(RMI2DSensorReport *report)

// Force touch emulation only works with clickpads (button underneath trackpad)
// Lock finger in place and in force touch until lifted
if (isForceTouch(obj.z)) {
// Checks for VALID input before registering as force touch
if (isForceTouch(obj.z) && fingerState[i] == RMI_FINGER_VALID) {
fingerState[i] = RMI_FINGER_FORCE_TOUCH;
}

Expand All @@ -234,7 +235,7 @@ void RMITrackpadFunction::handleReport(RMI2DSensorReport *report)
transducer.currentCoordinates.pressure = 0;
break;
}

transducer.isPhysicalButtonDown = false;
transducer.currentCoordinates = transducer.previousCoordinates;
transducer.currentCoordinates.pressure = RMI_MT2_MAX_PRESSURE;
Expand Down