diff options
author | Zephaniah E. Hull <warp@aehallh.com> | 2006-05-14 11:55:50 +0000 |
---|---|---|
committer | Zephaniah E. Hull <warp@aehallh.com> | 2006-05-14 11:55:50 +0000 |
commit | e9c60da89a9c55b81b2dedcf6ee3d1aefb4ff591 (patch) | |
tree | 906e82e20eb2cc084f92a060e9dec27d854e6adc /src/evdev_btn.c | |
parent | xf86-input-evdev v1.1.2 (diff) | |
download | xf86-input-evdev-e9c60da89a9c55b81b2dedcf6ee3d1aefb4ff591.tar.gz xf86-input-evdev-e9c60da89a9c55b81b2dedcf6ee3d1aefb4ff591.tar.bz2 xf86-input-evdev-e9c60da89a9c55b81b2dedcf6ee3d1aefb4ff591.zip |
Tweak credits and references.
Change the longs to unsigned longs in the bitfields.
Cleanup our includes.
Stop pulling in asm/types.h and asm/bitops.h.
Conditionally define the stuff that used to come from the above, including
our own test_bit, set_bit and clear_bit.
Change the longs to unsigned longs in the bitfields.
Change the longs to unsigned longs in the bitfields.
Use the bitop defines in evdev.h properly.
Change the longs to unsigned longs in the bitfields.
Change the longs to unsigned longs in the bitfields.
Use the bitop defines in evdev.h properly.
Change the longs to unsigned longs in the bitfields.
Use the bitop defines in evdev.h properly.
Add HPPA/HPPA64 entries. (Thanks to Fabio M. Di Nitto
<fabbione@ubuntu.com>)
Diffstat (limited to 'src/evdev_btn.c')
-rw-r--r-- | src/evdev_btn.c | 11 |
1 files changed, 1 insertions, 10 deletions
diff --git a/src/evdev_btn.c b/src/evdev_btn.c index 4c25245..35edee1 100644 --- a/src/evdev_btn.c +++ b/src/evdev_btn.c @@ -51,15 +51,6 @@ #include <xf86Module.h> - -#define ArrayLength(a) (sizeof(a) / (sizeof((a)[0]))) - -#define BITS_PER_LONG (sizeof(long) * 8) -#define NBITS(x) ((((x)-1)/BITS_PER_LONG)+1) -#define OFF(x) ((x)%BITS_PER_LONG) -#define LONG(x) ((x)/BITS_PER_LONG) -#define TestBit(bit, array) ((array[LONG(bit)] >> OFF(bit)) & 1) - void EvdevBtnPostFakeClicks(InputInfoPtr pInfo, int button, int count) { @@ -186,7 +177,7 @@ EvdevBtnNew(InputInfoPtr pInfo) state->btn = Xcalloc (sizeof (evdevBtnRec)); for (i = BTN_MISC; i < (KEY_OK - 1); i++) - if (TestBit (i, pEvdev->bits.key)) { + if (test_bit (i, pEvdev->bits.key)) { bit = i; if ((bit >= BTN_MOUSE) && (bit < BTN_JOYSTICK)) { bit -= BTN_MOUSE - BTN_MISC; |