diff options
author | Ross Burton <ross@burtonini.com> | 2008-04-22 16:37:02 +0100 |
---|---|---|
committer | Ross Burton <ross@burtonini.com> | 2008-04-22 16:37:02 +0100 |
commit | 20a90bef8b4993f06cf76ad05e3d4c974e1614f6 (patch) | |
tree | 602a39ad852c278ce6444b6ed0b6ff9d4c5ab7b3 | |
parent | b44e89f4683ffcfd75eaf39f1f37d7461db44689 (diff) |
Add a default touchscreen path
When enabling the touchscreen, open /dev/input/touchscreen0 if no path was
specified.
-rw-r--r-- | hw/kdrive/linux/tslib.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/hw/kdrive/linux/tslib.c b/hw/kdrive/linux/tslib.c index 371aeced9..50cd7cbd2 100644 --- a/hw/kdrive/linux/tslib.c +++ b/hw/kdrive/linux/tslib.c @@ -114,6 +114,10 @@ TslibEnable (KdPointerInfo *pi) private->raw_event_hook = NULL; private->raw_event_closure = NULL; + if (!pi->path) { + pi->path = "/dev/input/touchscreen0"; + ErrorF("[tslib/TslibEnable] no device path given, trying %s\n", pi->path); + } private->tsDev = ts_open(pi->path, 0); private->fd = ts_fd(private->tsDev); if (!private->tsDev || ts_config(private->tsDev) || private->fd < 0) { |