diff options
author | Peter Hutterer <peter.hutterer@who-t.net> | 2012-05-23 13:51:14 +1000 |
---|---|---|
committer | Peter Hutterer <peter.hutterer@who-t.net> | 2012-05-31 14:56:49 +1000 |
commit | d266408ed17b81edcf23625258f8859d6cbd43c0 (patch) | |
tree | 72030aa3e74d1ac43f5b424e5e0c5ee04ed3ac47 | |
parent | bc96940d4a9b81fa51fa3e7b9d35880bbbb22056 (diff) |
Remove typedefs from all enums
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
-rw-r--r-- | src/synaptics.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/src/synaptics.c b/src/synaptics.c index ac045ea..b370950 100644 --- a/src/synaptics.c +++ b/src/synaptics.c @@ -69,7 +69,7 @@ #include "synaptics.h" -typedef enum { +enum EdgeType { NO_EDGE = 0, BOTTOM_EDGE = 1, TOP_EDGE = 2, @@ -79,7 +79,7 @@ typedef enum { RIGHT_BOTTOM_EDGE = BOTTOM_EDGE | RIGHT_EDGE, RIGHT_TOP_EDGE = TOP_EDGE | RIGHT_EDGE, LEFT_TOP_EDGE = TOP_EDGE | LEFT_EDGE -} edge_type; +}; /* * We expect to be receiving a steady 80 packets/sec (which gives 40 @@ -687,10 +687,10 @@ diffa(double a1, double a2) return da; } -static edge_type +static enum EdgeType edge_detection(SynapticsPrivate * priv, int x, int y) { - edge_type edge = NO_EDGE; + enum EdgeType edge = NO_EDGE; if (x > priv->synpara.right_edge) edge |= RIGHT_EDGE; @@ -990,7 +990,7 @@ SynapticsDetectFinger(SynapticsPrivate * priv, struct SynapticsHwState *hw) } static void -SelectTapButton(SynapticsPrivate * priv, edge_type edge) +SelectTapButton(SynapticsPrivate * priv, enum EdgeType edge) { TapEvent tap; @@ -1102,7 +1102,7 @@ HandleTapProcessing(SynapticsPrivate * priv, struct SynapticsHwState *hw, SynapticsParameters *para = &priv->synpara; Bool touch, release, is_timeout, move, press; int timeleft, timeout; - edge_type edge; + enum EdgeType edge; int delay = 1000000000; if (priv->finger_state == FS_BLOCKED) @@ -1340,7 +1340,7 @@ hysteresis(int in, int center, int margin) static void get_delta(SynapticsPrivate *priv, const struct SynapticsHwState *hw, - edge_type edge, double *dx, double *dy) + enum EdgeType edge, double *dx, double *dy) { double dtime = (hw->millis - HIST(0).millis) / 1000.0; double integral; @@ -1374,7 +1374,7 @@ get_delta(SynapticsPrivate *priv, const struct SynapticsHwState *hw, */ static int ComputeDeltas(SynapticsPrivate * priv, const struct SynapticsHwState *hw, - edge_type edge, int *dxP, int *dyP, Bool inside_area) + enum EdgeType edge, int *dxP, int *dyP, Bool inside_area) { enum MovingState moving_state; double dx, dy; @@ -1518,7 +1518,7 @@ stop_coasting(SynapticsPrivate * priv) static int HandleScrolling(SynapticsPrivate * priv, struct SynapticsHwState *hw, - edge_type edge, Bool finger) + enum EdgeType edge, Bool finger) { SynapticsParameters *para = &priv->synpara; int delay = 1000000000; @@ -2084,7 +2084,7 @@ HandleState(SynapticsPrivate *priv, struct SynapticsHwState *hw, unsigned int no SynapticsParameters *para = &priv->synpara; enum FingerState finger = FS_UNTOUCHED; int dx = 0, dy = 0, buttons, id; - edge_type edge = NO_EDGE; + enum EdgeType edge = NO_EDGE; int change; int double_click = FALSE; int delay = 1000000000; |