tablet: rename STYLUS_IN_CONTACT to TOOL_IN_CONTACT

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
This commit is contained in:
Peter Hutterer 2015-11-11 13:44:02 +10:00
parent 480a72829a
commit 003e9b14d7
2 changed files with 4 additions and 4 deletions

View file

@ -496,9 +496,9 @@ tablet_process_key(struct tablet_dispatch *tablet,
break;
case BTN_TOUCH:
if (e->value)
tablet_set_status(tablet, TABLET_STYLUS_IN_CONTACT);
tablet_set_status(tablet, TABLET_TOOL_IN_CONTACT);
else
tablet_unset_status(tablet, TABLET_STYLUS_IN_CONTACT);
tablet_unset_status(tablet, TABLET_TOOL_IN_CONTACT);
/* Fall through */
case BTN_LEFT:
@ -843,7 +843,7 @@ sanitize_tablet_axes(struct tablet_dispatch *tablet)
clear_bit(tablet->changed_axes, LIBINPUT_TABLET_AXIS_DISTANCE);
tablet->axes[LIBINPUT_TABLET_AXIS_DISTANCE] = 0;
} else if (bit_is_set(tablet->changed_axes, LIBINPUT_TABLET_AXIS_PRESSURE) &&
!tablet_has_status(tablet, TABLET_STYLUS_IN_CONTACT)) {
!tablet_has_status(tablet, TABLET_TOOL_IN_CONTACT)) {
/* Make sure that the last axis value sent to the caller is a 0 */
if (tablet->axes[LIBINPUT_TABLET_AXIS_PRESSURE] == 0)
clear_bit(tablet->changed_axes,

View file

@ -35,7 +35,7 @@ enum tablet_status {
TABLET_AXES_UPDATED = 1 << 0,
TABLET_BUTTONS_PRESSED = 1 << 1,
TABLET_BUTTONS_RELEASED = 1 << 2,
TABLET_STYLUS_IN_CONTACT = 1 << 3,
TABLET_TOOL_IN_CONTACT = 1 << 3,
TABLET_TOOL_LEAVING_PROXIMITY = 1 << 4,
TABLET_TOOL_OUT_OF_PROXIMITY = 1 << 5,
TABLET_TOOL_ENTERING_PROXIMITY = 1 << 6