aboutsummaryrefslogtreecommitdiff
path: root/src/evdev_axes.c
diff options
context:
space:
mode:
authorZephaniah E. Hull <warp@aehallh.com>2006-04-09 00:41:42 +0000
committerZephaniah E. Hull <warp@aehallh.com>2006-04-09 00:41:42 +0000
commitc968040cde4e1a7c73332701008f6abfb1fa3ab3 (patch)
tree781fe874af05337bac3981ef4f75ac7bb7337079 /src/evdev_axes.c
parentDropped the xorg-xserver 1.0.99.901 requirement. (Things were tweaked to (diff)
downloadxf86-input-evdev-c968040cde4e1a7c73332701008f6abfb1fa3ab3.tar.gz
xf86-input-evdev-c968040cde4e1a7c73332701008f6abfb1fa3ab3.tar.bz2
xf86-input-evdev-c968040cde4e1a7c73332701008f6abfb1fa3ab3.zip
Remove a debugging message.
Actually, well, _work_. Note, abs support still segfaults, I'll debug it after I've slept. But I should get it tomorrow.
Diffstat (limited to 'src/evdev_axes.c')
-rw-r--r--src/evdev_axes.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/src/evdev_axes.c b/src/evdev_axes.c
index a164f84..55de247 100644
--- a/src/evdev_axes.c
+++ b/src/evdev_axes.c
@@ -485,11 +485,19 @@ EvdevAxisRelNew(InputInfoPtr pInfo)
int
EvdevAxesNew (InputInfoPtr pInfo)
{
+ evdevDevicePtr pEvdev = pInfo->private;
+ evdevStatePtr state = &pEvdev->state;
int ret = Success;
+
+ state->axes = Xcalloc (sizeof (evdevAxesRec));
if (EvdevAxisAbsNew(pInfo) != Success)
ret = !Success;
if (EvdevAxisRelNew(pInfo) != Success)
ret = !Success;
+ if (!state->abs && !state->rel) {
+ Xfree (state->axes);
+ state->axes = NULL;
+ }
return ret;
}
@@ -511,9 +519,13 @@ EvdevAxesInit (DeviceIntPtr device)
if (state->abs && state->abs->axes > axes)
axes = state->abs->axes;
- if (state->abs && state->rel->axes > axes)
+ if (state->rel && state->rel->axes > axes)
axes = state->rel->axes;
+ state->axes->axes = axes;
+
+ xf86Msg(X_CONFIG, "%s: %d valuators.\n", pInfo->name,
+ axes);
if (!axes)
return Success;