From f79dd7c4e818464faa84e7ae35b88988a9535aee Mon Sep 17 00:00:00 2001 From: ian Date: Sun, 13 Jul 2008 22:31:43 +0000 Subject: [PATCH] use --redact rather than --dump --- hostside/gui | 29 ++++++++++++++++++----------- 1 file changed, 18 insertions(+), 11 deletions(-) diff --git a/hostside/gui b/hostside/gui index 9e29278..731f751 100755 --- a/hostside/gui +++ b/hostside/gui @@ -506,7 +506,7 @@ proc ib-wheelmouse-stepmap {offset oldspeed} { return [lindex $map $ix] } -proc ib-ev/wheelmouse/EV_REL/REL_WHEEL {w value} { +proc ib-ev/wheelmouse/EV_REL/REL_WHEEL {devid value} { upvar #0 input/$devid in if {$value<0} { if {[speedw-uninhibit $in(speedw) 2]>0} { incr value 1 } @@ -526,7 +526,11 @@ proc ib-create/wheelmouse {devid wunique desc} { } proc ib-evcmd/wheelmouse {devid target} { - return [ib-evcmd-construct $devid $target --grab] + return [ib-evcmd-construct $devid $target { + --grab + --redaction EV REL REL X --suppress + --redaction EV REL REL Y --suppress + }] } #---------- input device evdev binding ---------- @@ -534,8 +538,9 @@ proc ib-evcmd/wheelmouse {devid target} { proc ib-evcmd-construct {devid target xargs} { upvar #0 input/$devid in manyset $target ev sysfs + if {[regexp { } $ev]} { error "event device `$ev' contains space" } return [concat \ - [list ./evdev-manip] $xargs \ + [list ./evdev-manip --redact] $xargs \ [list --stdin-monitor \ --expect-sysfs /sys$sysfs/$ev/dev \ /dev/input/$ev]] @@ -661,21 +666,23 @@ proc input-binding-inputline {chan l devid} { # give the input binding first dibs if {[ib-inputline/$in(concrete) $devid $l]} return } - switch -glob -- $l { - {device *} { + regsub {^[^ ]+ } $l {} lr + switch -glob -- $lr { + {opened *} { debug "ib $devid start << $l" if {[info exists in(speedw)]} { speedw-setstate $in(speedw) normal } } - {event *} { - manyset [split $l] dummy dummy kind code value - set proc ib/$in(concrete)/$kind/$code - if {[catch { info args $proc }]} return + {[-0-9]*} { + manyset [split $lr] value kindl kindr codel coder + set proc ib-ev/$in(concrete)/${kindl}_${kindr}/${codel}_${coder} + if {[catch { info args $proc }]} { + debug "ib $devid unbound $proc <<" + return + } $proc $devid $value } - {report-from *} { } - {synch *} { } * { debug "ib $devid ignored << $l" } -- 2.30.2