summaryrefslogtreecommitdiff
path: root/test/litest-int.h
diff options
context:
space:
mode:
authorPeter Hutterer <peter.hutterer@who-t.net>2015-07-06 16:26:21 +1000
committerPeter Hutterer <peter.hutterer@who-t.net>2015-07-09 11:27:53 +1000
commit4a3288dc59e2f1211c8f69dca3eb4b9ea4059482 (patch)
tree2399bd11631c03e61997e7de25fb3b6de7397af5 /test/litest-int.h
parent7d314738fb7cb351d08b9860158bfb41975fb6c0 (diff)
downloadlibinput-4a3288dc59e2f1211c8f69dca3eb4b9ea4059482.tar.gz
test: allow for a default value on LITEST_AUTO_ASSIGNS
The touchpads currently all send a default value of 30 for ABS_PRESSURE. For some tests we want to have a custom pressure but changing all tests isn't sensible. So hook each device up to send a default value of 30 if it isn't overridden in the test itself. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net> Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Diffstat (limited to 'test/litest-int.h')
-rw-r--r--test/litest-int.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/test/litest-int.h b/test/litest-int.h
index 666c5ff9..ab611a56 100644
--- a/test/litest-int.h
+++ b/test/litest-int.h
@@ -80,6 +80,12 @@ struct litest_device_interface {
void (*touch_up)(struct litest_device *d, unsigned int slot);
/**
+ * Default value for the given EV_ABS axis.
+ * @return 0 on success, nonzero otherwise
+ */
+ int (*get_axis_default)(struct litest_device *d, unsigned int code, int32_t *value);
+
+ /**
* Set of of events to execute on touch down, terminated by a .type
* and .code value of -1. If the event value is LITEST_AUTO_ASSIGN,
* it will be automatically assigned by the framework (valid for x,