summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorPeter Hutterer <peter.hutterer@who-t.net>2011-12-07 14:14:10 +1000
committerPeter Hutterer <peter.hutterer@who-t.net>2011-12-10 17:54:34 +1000
commite5aa00989cda9ebd18063c5e955235123ad37b88 (patch)
treec835110c16fa436c73b681dda9aadbc511f9b186 /test
parent6cc0e6a0afa6a87802767d484aa4e68fa935d3eb (diff)
Change GetXI2/XI/CoreType to just take a type argument
Avoids the dummy-event dance if we have an event type and need to get the matching XI2 type. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net> Reviewed-by: Chase Douglas <chase.douglas@canonical.com>
Diffstat (limited to 'test')
-rw-r--r--test/xi2/protocol-eventconvert.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/test/xi2/protocol-eventconvert.c b/test/xi2/protocol-eventconvert.c
index dce1c50c4..e2037f911 100644
--- a/test/xi2/protocol-eventconvert.c
+++ b/test/xi2/protocol-eventconvert.c
@@ -59,7 +59,7 @@ static void test_values_XIRawEvent(RawDeviceEvent *in, xXIRawEvent *out,
assert(out->type == GenericEvent);
assert(out->extension == 0); /* IReqCode defaults to 0 */
- assert(out->evtype == GetXI2Type((InternalEvent*)in));
+ assert(out->evtype == GetXI2Type(in->type));
assert(out->time == in->time);
assert(out->detail == in->detail.button);
assert(out->deviceid == in->deviceid);
@@ -305,7 +305,7 @@ static void test_values_XIDeviceEvent(DeviceEvent *in, xXIDeviceEvent *out,
}
assert(out->extension == 0); /* IReqCode defaults to 0 */
- assert(out->evtype == GetXI2Type((InternalEvent*)in));
+ assert(out->evtype == GetXI2Type(in->type));
assert(out->time == in->time);
assert(out->detail == in->detail.button);
assert(out->length >= 12);
@@ -662,7 +662,7 @@ static void test_values_XIDeviceChangedEvent(DeviceChangedEvent *in,
assert(out->type == GenericEvent);
assert(out->extension == 0); /* IReqCode defaults to 0 */
- assert(out->evtype == GetXI2Type((InternalEvent*)in));
+ assert(out->evtype == GetXI2Type(in->type));
assert(out->time == in->time);
assert(out->deviceid == in->deviceid);
assert(out->sourceid == in->sourceid);