[PATCH synaptics 11/12] move history storage from ComputeDeltas into HandleState.

Peter Hutterer peter.hutterer at who-t.net
Thu May 6 21:42:03 PDT 2010


It's well hidden in there, but not useful.

Signed-off-by: Peter Hutterer <peter.hutterer at who-t.net>
---
 src/synaptics.c |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/src/synaptics.c b/src/synaptics.c
index 907335a..88c5237 100644
--- a/src/synaptics.c
+++ b/src/synaptics.c
@@ -1582,7 +1582,7 @@ estimate_delta(double x0, double x1, double x2, double x3)
 }
 
 static int
-ComputeDeltas(SynapticsPrivate *priv, struct SynapticsHwState *hw,
+ComputeDeltas(SynapticsPrivate *priv, const struct SynapticsHwState const *hw,
 	      edge_type edge, int *dxP, int *dyP)
 {
     SynapticsParameters *para = &priv->synpara;
@@ -1718,9 +1718,6 @@ ComputeDeltas(SynapticsPrivate *priv, struct SynapticsHwState *hw,
     *dxP = dx;
     *dyP = dy;
 
-    /* generate a history of the absolute positions */
-    store_history(priv, hw->x, hw->y, hw->millis);
-
     return delay;
 }
 
@@ -2337,6 +2334,9 @@ HandleState(LocalDevicePtr local, struct SynapticsHwState *hw)
     priv->finger_state = finger;
     priv->lastButtons = buttons;
 
+    /* generate a history of the absolute positions */
+    store_history(priv, hw->x, hw->y, hw->millis);
+
     return delay;
 }
 
-- 
1.6.6.1



More information about the xorg-devel mailing list