From: ian Date: Sun, 8 Jun 2008 12:48:48 +0000 (+0000) Subject: InputEventState, preparatory to deletion etc. X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ijackson/git?a=commitdiff_plain;h=6bfa53a253ecaea52cd07316410afcce86da5e3e;p=trains.git InputEventState, preparatory to deletion etc. --- diff --git a/hostside/evdev-manip.c b/hostside/evdev-manip.c index 34ec916..5c9fbea 100644 --- a/hostside/evdev-manip.c +++ b/hostside/evdev-manip.c @@ -17,6 +17,8 @@ #include #include + +typedef struct InputEventState InputEventState; #include "input-codes.h" /* not really a header */ typedef struct { @@ -42,7 +44,7 @@ static const char *expect_sysfs; static void pr_hex(unsigned long value) { printf("%#lx",value); } -#define PR_TABLE_STR(tab, val) (pr_table_str(iesis_##tab, iesin_##tab, (val))) +#define PR_TABLE_STR(tab, val) (pr_table_str(iesis_##tab, ien_##tab, (val))) static void pr_table_str(const InputEventStringInfo *strings, int nstrings, unsigned long value) { const InputEventStringInfo *string; diff --git a/hostside/extract-input-codes b/hostside/extract-input-codes index f95b222..07d988e 100755 --- a/hostside/extract-input-codes +++ b/hostside/extract-input-codes @@ -43,7 +43,7 @@ while (<>) { } } -our ($i,$iesis,$iesin,$n,$si); +our ($i,$iesis,$ien,$n,$si); print <[$i]; $tab= defined $si ? $si->[1] : undef; $tab= $tab && exists $evtypes{$tab} ? $tab : undef; - @sip= $tab ? ("IESIN_$tab", "iesis_\L$tab") : ("-1", "0"); + @sip= $tab ? ("IEN_$tab", "iesis_\L$tab", "iess_\L$tab") : (-1, 0, 0); print_i(); - printf " { %-21s %-20s },\n", "$sip[0],", $sip[1] + printf " { %-16s %-15s %-15s },\n", "$sip[0],", "$sip[1],", $sip[2], or die $!; } print <