aboutsummaryrefslogtreecommitdiff
path: root/xorg-server/hw/dmx/input/dmxinputinit.c
diff options
context:
space:
mode:
Diffstat (limited to 'xorg-server/hw/dmx/input/dmxinputinit.c')
-rw-r--r--xorg-server/hw/dmx/input/dmxinputinit.c16
1 files changed, 6 insertions, 10 deletions
diff --git a/xorg-server/hw/dmx/input/dmxinputinit.c b/xorg-server/hw/dmx/input/dmxinputinit.c
index 0ea3e0953..4b10ecb17 100644
--- a/xorg-server/hw/dmx/input/dmxinputinit.c
+++ b/xorg-server/hw/dmx/input/dmxinputinit.c
@@ -476,7 +476,8 @@ static int dmxDeviceOnOff(DeviceIntPtr pDevice, int what)
InitValuatorAxisStruct(pDevice, i, axis_labels[i],
info.minval[i], info.maxval[i],
info.res[i],
- info.minres[i], info.maxres[i]);
+ info.minres[i], info.maxres[i],
+ Relative);
} else if (info.numRelAxes) {
InitValuatorClassDeviceStruct(pDevice, info.numRelAxes,
axis_labels,
@@ -486,7 +487,8 @@ static int dmxDeviceOnOff(DeviceIntPtr pDevice, int what)
InitValuatorAxisStruct(pDevice, i, axis_labels[i],
info.minval[i],
info.maxval[i], info.res[i],
- info.minres[i], info.maxres[i]);
+ info.minres[i], info.maxres[i],
+ Relative);
} else if (info.numAbsAxes) {
InitValuatorClassDeviceStruct(pDevice, info.numAbsAxes,
axis_labels,
@@ -497,7 +499,7 @@ static int dmxDeviceOnOff(DeviceIntPtr pDevice, int what)
axis_labels[i],
info.minval[i], info.maxval[i],
info.res[i], info.minres[i],
- info.maxres[i]);
+ info.maxres[i], Absolute);
}
}
if (info.focusClass) InitFocusClassDeviceStruct(pDevice);
@@ -693,7 +695,6 @@ static DeviceIntPtr dmxAddDevice(DMXLocalInputInfoPtr dmxLocal)
DeviceIntPtr pDevice;
Atom atom;
const char *name = NULL;
- void (*registerProcPtr)(DeviceIntPtr) = NULL;
char *devname;
DMXInputInfo *dmxInput;
@@ -706,22 +707,19 @@ static DeviceIntPtr dmxAddDevice(DMXLocalInputInfoPtr dmxLocal)
dmxLocal->isCore = 1;
dmxLocalCoreKeyboard = dmxLocal;
name = "keyboard";
- registerProcPtr = RegisterKeyboardDevice;
}
if (dmxLocal->type == DMX_LOCAL_MOUSE && !dmxLocalCorePointer) {
dmxLocal->isCore = 1;
dmxLocalCorePointer = dmxLocal;
name = "pointer";
- registerProcPtr = RegisterPointerDevice;
}
}
if (!name) {
name = "extension";
- registerProcPtr = RegisterOtherDevice;
}
- if (!name || !registerProcPtr)
+ if (!name)
dmxLog(dmxFatal, "Cannot add device %s\n", dmxLocal->name);
pDevice = AddInputDevice(serverClient, dmxDeviceOnOff, TRUE);
@@ -738,8 +736,6 @@ static DeviceIntPtr dmxAddDevice(DMXLocalInputInfoPtr dmxLocal)
pDevice->type = atom;
pDevice->name = devname;
- registerProcPtr(pDevice);
-
if (dmxLocal->isCore && dmxLocal->type == DMX_LOCAL_MOUSE) {
#if 00 /*BP*/
miRegisterPointerDevice(screenInfo.screens[0], pDevice);