From: Chris Bagwell <ch...@cnpbagwell.com> Protocol 4 and Generic hard code PAD device to use only last channel. Create #define for this case to improve readability. --- src/wcmUSB.c | 4 ++-- src/xf86WacomDefs.h | 1 + 2 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/src/wcmUSB.c b/src/wcmUSB.c index c25e67c..02cfa05 100644 --- a/src/wcmUSB.c +++ b/src/wcmUSB.c @@ -582,7 +582,7 @@ static int usbChooseChannel(WacomCommonPtr common) * and all other button presses to PAD. Hardcode PAD * channel here. */ - private->wcmBTNChannel = MAX_CHANNELS-1; + private->wcmBTNChannel = PAD_CHANNEL; } else if (common->wcmProtocolLevel == WCM_PROTOCOL_4) { @@ -610,7 +610,7 @@ static int usbChooseChannel(WacomCommonPtr common) * pad devices. */ if (serial == 0xf0) - channel = MAX_CHANNELS-1; + channel = PAD_CHANNEL; else if (serial) channel = serial-1; else diff --git a/src/xf86WacomDefs.h b/src/xf86WacomDefs.h index 714be79..aae1b56 100644 --- a/src/xf86WacomDefs.h +++ b/src/xf86WacomDefs.h @@ -387,6 +387,7 @@ extern WacomDeviceClass gWacomISDV4Device; #define RAW_FILTERING_FLAG 4 #define MAX_CHANNELS 3 +#define PAD_CHANNEL (MAX_CHANNELS-1) #define MAX_FINGERS 2 typedef struct { -- 1.7.3.4 ------------------------------------------------------------------------------ Gaining the trust of online customers is vital for the success of any company that requires sensitive data to be transmitted over the Web. Learn how to best implement a security strategy that keeps consumers' information secure and instills the confidence they need to proceed with transactions. http://p.sf.net/sfu/oracle-sfdevnl _______________________________________________ Linuxwacom-devel mailing list Linuxwacom-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linuxwacom-devel