diff options
author | marha <marha@users.sourceforge.net> | 2011-10-05 17:44:57 +0200 |
---|---|---|
committer | marha <marha@users.sourceforge.net> | 2011-10-05 17:44:57 +0200 |
commit | 8af87a5b60e37ae84fdd759e2c1602be38be4905 (patch) | |
tree | 2e621c7fbdc4dfe9eb8d733af4cc232bc03643d4 /xorg-server/dix/devices.c | |
parent | 8238de0fe0c28bd54b3e6cdd1fc94513cf21d3cc (diff) | |
parent | f7025b4baa1ba35ee796785641f04eac5bedb0a6 (diff) | |
download | vcxsrv-8af87a5b60e37ae84fdd759e2c1602be38be4905.tar.gz vcxsrv-8af87a5b60e37ae84fdd759e2c1602be38be4905.tar.bz2 vcxsrv-8af87a5b60e37ae84fdd759e2c1602be38be4905.zip |
Merge remote-tracking branch 'origin/released'
Conflicts:
mesalib/src/mapi/glapi/glapi.h
mesalib/src/mesa/main/syncobj.h
xorg-server/dix/events.c
xorg-server/dix/getevents.c
xorg-server/include/misc.h
Diffstat (limited to 'xorg-server/dix/devices.c')
-rw-r--r-- | xorg-server/dix/devices.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/xorg-server/dix/devices.c b/xorg-server/dix/devices.c index b6f7ea697..73c4d1460 100644 --- a/xorg-server/dix/devices.c +++ b/xorg-server/dix/devices.c @@ -264,6 +264,8 @@ AddInputDevice(ClientPtr client, DeviceProc deviceProc, Bool autoStart) offsetof(DeviceIntRec, devPrivates), PRIVATE_DEVICE); if (!dev) return (DeviceIntPtr)NULL; + + dev->last.scroll = NULL; dev->id = devid; dev->public.processInputProc = ProcessOtherEvent; dev->public.realInputProc = ProcessOtherEvent; @@ -943,6 +945,7 @@ CloseDevice(DeviceIntPtr dev) free(dev->deviceGrab.sync.event); free(dev->config_info); /* Allocated in xf86ActivateDevice. */ + free(dev->last.scroll); dev->config_info = NULL; dixFreeObjectWithPrivates(dev, PRIVATE_DEVICE); } @@ -1285,10 +1288,19 @@ InitValuatorClassDeviceStruct(DeviceIntPtr dev, int numAxes, Atom *labels, if (!valc) return FALSE; + dev->last.scroll = valuator_mask_new(numAxes); + if (!dev->last.scroll) + { + free(valc); + return FALSE; + } + valc->sourceid = dev->id; valc->motion = NULL; valc->first_motion = 0; valc->last_motion = 0; + valc->h_scroll_axis = -1; + valc->v_scroll_axis = -1; valc->numMotionEvents = numMotionEvents; valc->motionHintWindow = NullWindow; |