Module Name: xsrc
Committed By: mrg
Date: Tue Aug 18 05:34:17 UTC 2009
Modified Files:
xsrc/external/mit/xf86-input-mouse/dist/src: mouse.c mouse.h
Log Message:
fix the rest of PR 41902: make the mouse re-init wsmouse version.
the later mouse init changes the "protocol" away from "wsmouse", so
we don't bother testing for wsmouse but just try it anyway.
also, reduce (useless?) netbsd diffs to vendor.
To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 xsrc/external/mit/xf86-input-mouse/dist/src/mouse.c
cvs rdiff -u -r1.2 -r1.3 xsrc/external/mit/xf86-input-mouse/dist/src/mouse.h
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: xsrc/external/mit/xf86-input-mouse/dist/src/mouse.c
diff -u xsrc/external/mit/xf86-input-mouse/dist/src/mouse.c:1.7 xsrc/external/mit/xf86-input-mouse/dist/src/mouse.c:1.8
--- xsrc/external/mit/xf86-input-mouse/dist/src/mouse.c:1.7 Wed Jul 8 09:04:37 2009
+++ xsrc/external/mit/xf86-input-mouse/dist/src/mouse.c Tue Aug 18 05:34:17 2009
@@ -128,9 +128,8 @@
} DragLockRec, *DragLockPtr;
-#ifdef __NetBSD__
+
static const OptionInfoRec *MouseAvailableOptions(void *unused);
-#endif
static InputInfoPtr MousePreInit(InputDriverPtr drv, IDevPtr dev, int flags);
#if 0
static void MouseUnInit(InputDriverPtr drv, InputInfoPtr pInfo, int flags);
@@ -178,7 +177,6 @@
0
};
-#ifdef __NetBSD__
typedef enum {
OPTION_ALWAYS_CORE,
OPTION_SEND_CORE_EVENTS,
@@ -263,7 +261,6 @@
{ OPTION_SENSITIVITY, "Sensitivity", OPTV_REAL, {0}, FALSE },
{ -1, NULL, OPTV_NONE, {0}, FALSE }
};
-#endif
#define RETRY_COUNT 4
@@ -380,14 +377,12 @@
{ NULL, MSE_NONE, NULL, PROT_UNKNOWN }
};
-#ifdef __NetBSD__
/*ARGSUSED*/
static const OptionInfoRec *
MouseAvailableOptions(void *unused)
{
return (mouseOptions);
}
-#endif
/* Process options common to all mouse types. */
static void
@@ -876,7 +871,6 @@
}
}
-#ifdef __NetBSD__
_X_EXPORT const char *
xf86MouseProtocolIDToName(MouseProtocolID id)
{
@@ -888,7 +882,6 @@
{
return ProtocolNameToID(name);
}
-#endif
static int
ProtocolIDToClass(MouseProtocolID id)
@@ -1764,11 +1757,9 @@
xf86Msg(X_WARNING, "%s: cannot open input device\n", pInfo->name);
else {
#if defined(__NetBSD__) && defined(WSCONS_SUPPORT) && defined(WSMOUSEIO_SETVERSION)
- if (!strcasecmp(pMse->protocol, "wsmouse")) {
- int version = WSMOUSE_EVENT_VERSION;
- if (ioctl(pInfo->fd, WSMOUSEIO_SETVERSION, &version) == -1)
- xf86Msg(X_WARNING, "%s: cannot set version\n", pInfo->name);
- }
+ int version = WSMOUSE_EVENT_VERSION;
+ if (ioctl(pInfo->fd, WSMOUSEIO_SETVERSION, &version) == -1)
+ xf86Msg(X_WARNING, "%s: cannot set version\n", pInfo->name);
#endif
if (pMse->xisbscale)
pMse->buffer = XisbNew(pInfo->fd, pMse->xisbscale * 4);
@@ -3769,7 +3760,7 @@
/**************** end of autoprobe stuff *****************/
-#ifdef __NetBSD__
+
ModuleInfoRec MouseInfo = {
1,
"MOUSE",
@@ -3777,7 +3768,6 @@
0,
MouseAvailableOptions,
};
-#endif
static void
xf86MouseUnplug(pointer p)
Index: xsrc/external/mit/xf86-input-mouse/dist/src/mouse.h
diff -u xsrc/external/mit/xf86-input-mouse/dist/src/mouse.h:1.2 xsrc/external/mit/xf86-input-mouse/dist/src/mouse.h:1.3
--- xsrc/external/mit/xf86-input-mouse/dist/src/mouse.h:1.2 Wed Jul 8 09:04:37 2009
+++ xsrc/external/mit/xf86-input-mouse/dist/src/mouse.h Tue Aug 18 05:34:17 2009
@@ -7,9 +7,7 @@
#include "xf86OSmouse.h"
-#ifdef __NetBSD__
_X_EXPORT const char * xf86MouseProtocolIDToName(MouseProtocolID id);
MouseProtocolID xf86MouseProtocolNameToID(const char *name);
-#endif
#endif