input_server/tablet: Only send event messages when pen is in range.
When the pen is moved out of range, the Wacom tablet sends one last message with all values set to 0 and the In Range value set to false. Don't send mouse event messages in this case. Change-Id: I419d57cede47a6ef40a160322f3025ef372ecaa3 Reviewed-on: https://review.haiku-os.org/c/1448 Reviewed-by: waddlesplash <[email protected]> Reviewed-by: Stephan Aßmus <[email protected]>
This commit is contained in:
committed by
Stephan Aßmus
parent
45c3eb3a3c
commit
7625dca0e9
@@ -322,6 +322,9 @@ TabletDevice::_ControlThread()
|
||||
movements.pressure, movements.wheel_xdelta, movements.wheel_ydelta,
|
||||
movements.eraser ? 'y' : 'n', movements.tilt_x, movements.tilt_y);
|
||||
|
||||
// Only send messages when pen is in range
|
||||
|
||||
if (movements.has_contact) {
|
||||
// Send single messages for each event
|
||||
|
||||
uint32 buttons = lastButtons ^ movements.buttons;
|
||||
@@ -380,6 +383,7 @@ TabletDevice::_ControlThread()
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void
|
||||
|
||||
Reference in New Issue
Block a user