ports/x11-drivers/xf86-input-acecad/files/patch-git_06_9385ae9
Baptiste Daroussin 1810e8dcb7 Import few patches from upstream to allow building with newer xorg
Note that those drivers are barely maintained and might disappear in the futur

PR:		216270
Submitted by:	matthew@reztek.cz
2017-01-23 22:22:53 +00:00

97 lines
3.4 KiB
Text

From 9385ae905aca9e679e698f0491e0bf7e30a35092 Mon Sep 17 00:00:00 2001
From: Cyril Brulebois <kibi@debian.org>
Date: Fri, 3 Jun 2011 15:59:16 +0200
Subject: Remove pointless checks on is_core_pointer.
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Signed-off-by: Cyril Brulebois <kibi@debian.org>
diff --git a/src/acecad.c b/src/acecad.c
index de2577e..ad6d793 100644
--- src/acecad.c
+++ src/acecad.c
@@ -729,7 +729,7 @@ ReadInput (InputInfoPtr local)
{
int x, y, z;
int prox, buttons;
- int is_core_pointer = 0, is_absolute;
+ int is_absolute;
AceCadPrivatePtr priv = (AceCadPrivatePtr) (local->private);
/*xf86Msg(X_INFO, "ACECAD Tablet Read Input\n");*/
@@ -772,11 +772,10 @@ ReadInput (InputInfoPtr local)
if (prox)
{
if (!(priv->acecadOldProximity))
- if (!is_core_pointer)
- {
- /*xf86Msg(X_INFO, "ACECAD Tablet ProxIN %d %d %d\n",x, y, z);*/
- xf86PostProximityEvent(local->dev, 1, 0, 3 , x, y, z);
- }
+ {
+ /*xf86Msg(X_INFO, "ACECAD Tablet ProxIN %d %d %d\n",x, y, z);*/
+ xf86PostProximityEvent(local->dev, 1, 0, 3 , x, y, z);
+ }
if ((is_absolute && ((priv->acecadOldX != x) || (priv->acecadOldY != y) || (priv->acecadOldZ != z)))
|| (!is_absolute && (x || y)))
@@ -809,12 +808,11 @@ ReadInput (InputInfoPtr local)
}
else
{
- if (!is_core_pointer)
- if (priv->acecadOldProximity)
- {
- /*xf86Msg(X_INFO, "ACECAD Tablet ProxOUT %d %d %d\n",x, y, z);*/
- xf86PostProximityEvent(local->dev, 0, 0, 3, x,y,z);
- }
+ if (priv->acecadOldProximity)
+ {
+ /*xf86Msg(X_INFO, "ACECAD Tablet ProxOUT %d %d %d\n",x, y, z);*/
+ xf86PostProximityEvent(local->dev, 0, 0, 3, x,y,z);
+ }
priv->acecadOldProximity = 0;
}
}
@@ -836,7 +834,6 @@ USBReadInput (InputInfoPtr local)
int report_x = 0, report_y = 0;
int prox = priv->acecadOldProximity;
int buttons = priv->acecadOldButtons;
- int is_core_pointer = 0;
/* Is autodev active? */
int autodev = priv->flags & AUTODEV_FLAG;
/* Was the device available last time we checked? */
@@ -935,10 +932,9 @@ USBReadInput (InputInfoPtr local)
report_y = y;
#endif
if (!(priv->acecadOldProximity))
- if (!is_core_pointer)
- {
- xf86PostProximityEvent(local->dev, 1, 0, 3 , report_x, report_y, z);
- }
+ {
+ xf86PostProximityEvent(local->dev, 1, 0, 3 , report_x, report_y, z);
+ }
xf86PostMotionEvent(local->dev, 1, 0, 3, report_x, report_y, z);
@@ -957,11 +953,10 @@ USBReadInput (InputInfoPtr local)
}
else
{
- if (!is_core_pointer)
- if (priv->acecadOldProximity)
- {
- xf86PostProximityEvent(local->dev, 0, 0, 3, report_x, report_y, z);
- }
+ if (priv->acecadOldProximity)
+ {
+ xf86PostProximityEvent(local->dev, 0, 0, 3, report_x, report_y, z);
+ }
priv->acecadOldProximity = 0;
}
--
cgit v0.10.2