mirror of
https://github.com/X11Libre/xf86-input-evdev.git
synced 2026-04-14 11:44:16 +00:00
Shut up "unused variable" compiler warnings.
Hide properties behind ifdefs, fake use of "val".
This commit is contained in:
@@ -42,11 +42,13 @@
|
||||
|
||||
#include "evdev.h"
|
||||
|
||||
#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) >= 3
|
||||
static const char *propname_dlock = "Drag Lock Buttons";
|
||||
|
||||
static Atom prop_dlock = 0; /* Drag lock buttons. */
|
||||
|
||||
void EvdevDragLockLockButton(InputInfoPtr pInfo, unsigned int button);
|
||||
#endif
|
||||
|
||||
|
||||
/* Setup and configuration code */
|
||||
|
||||
@@ -47,12 +47,14 @@ enum {
|
||||
MBEMU_AUTO
|
||||
};
|
||||
|
||||
#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) >= 3
|
||||
static const char *propname_mbemu = "Middle Button Emulation";
|
||||
static const char *propname_mbtimeout = "Middle Button Timeout";
|
||||
|
||||
static Atom prop_mbemu = 0; /* Middle button emulation on/off property */
|
||||
static Atom prop_mbtimeout = 0; /* Middle button timeout property */
|
||||
|
||||
#endif
|
||||
/*
|
||||
* Lets create a simple finite-state machine for 3 button emulation:
|
||||
*
|
||||
|
||||
@@ -43,6 +43,7 @@
|
||||
|
||||
#define WHEEL_NOT_CONFIGURED 0
|
||||
|
||||
#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) >= 3
|
||||
static const char *propname_wheel_emu = "Wheel Emulation";
|
||||
static const char *propname_wheel_xmap = "Wheel Emulation X Axis";
|
||||
static const char *propname_wheel_ymap = "Wheel Emulation Y Axis";
|
||||
@@ -50,12 +51,13 @@ static const char *propname_wheel_inertia = "Wheel Emulation Inertia";
|
||||
static const char *propname_wheel_timeout = "Wheel Emulation Timeout";
|
||||
static const char *propname_wheel_button = "Wheel Emulation Button";
|
||||
|
||||
static Atom prop_wheel_emu;
|
||||
static Atom prop_wheel_xmap;
|
||||
static Atom prop_wheel_ymap;
|
||||
static Atom prop_wheel_inertia;
|
||||
static Atom prop_wheel_timeout;
|
||||
static Atom prop_wheel_button;
|
||||
static Atom prop_wheel_emu = 0;
|
||||
static Atom prop_wheel_xmap = 0;
|
||||
static Atom prop_wheel_ymap = 0;
|
||||
static Atom prop_wheel_inertia = 0;
|
||||
static Atom prop_wheel_timeout = 0;
|
||||
static Atom prop_wheel_button = 0;
|
||||
#endif
|
||||
|
||||
/* Local Funciton Prototypes */
|
||||
static BOOL EvdevWheelEmuHandleButtonMap(InputInfoPtr pInfo, WheelAxisPtr pAxis, char *axis_name);
|
||||
@@ -235,7 +237,8 @@ EvdevWheelEmuPreInit(InputInfoPtr pInfo)
|
||||
int inertia;
|
||||
int timeout;
|
||||
|
||||
|
||||
val[0] = 0;
|
||||
val[1] = 0;
|
||||
|
||||
if (xf86SetBoolOption(pInfo->options, "EmulateWheel", FALSE)) {
|
||||
pEvdev->emulateWheel.enabled = TRUE;
|
||||
|
||||
Reference in New Issue
Block a user