summaryrefslogtreecommitdiff
path: root/src/mouse.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mouse.c')
-rw-r--r--src/mouse.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/src/mouse.c b/src/mouse.c
index 3ed2b46..3cdc63a 100644
--- a/src/mouse.c
+++ b/src/mouse.c
@@ -898,19 +898,20 @@ MousePreInit(InputDriverPtr drv, IDevPtr dev, int flags)
pInfo->always_core_feedback = NULL;
pInfo->conf_idev = dev;
- /* Check if SendDragEvents has been disabled. */
- if (!xf86SetBoolOption(dev->commonOptions, "SendDragEvents", TRUE)) {
- pInfo->flags &= ~XI86_SEND_DRAG_EVENTS;
- }
-
/* Allocate the MouseDevRec and initialise it. */
if (!(pMse = calloc(sizeof(MouseDevRec), 1)))
goto out;
+
pInfo->private = pMse;
pMse->Ctrl = MouseCtrl;
pMse->PostEvent = MousePostEvent;
pMse->CommonOptions = MouseCommonOptions;
-
+
+ /* Check if SendDragEvents has been disabled. */
+ if (!xf86SetBoolOption(dev->commonOptions, "SendDragEvents", TRUE)) {
+ pInfo->flags &= ~XI86_SEND_DRAG_EVENTS;
+ }
+
/* Find the protocol type. */
protocol = xf86SetStrOption(dev->commonOptions, "Protocol", NULL);
if (protocol) {