aboutsummaryrefslogtreecommitdiff
path: root/xorg-server/dix/touch.c
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2012-07-06 09:12:35 +0200
committermarha <marha@users.sourceforge.net>2012-07-06 09:13:41 +0200
commit336bad93d146931c160d8517edfdf0bee49ad9f7 (patch)
treed0fbdb5a716e78aa6318c7ddd49bd3e09e13379f /xorg-server/dix/touch.c
parentfc8f37239f3af088819c18f5632b2608954af73a (diff)
downloadvcxsrv-336bad93d146931c160d8517edfdf0bee49ad9f7.tar.gz
vcxsrv-336bad93d146931c160d8517edfdf0bee49ad9f7.tar.bz2
vcxsrv-336bad93d146931c160d8517edfdf0bee49ad9f7.zip
randrproto fontconfig mesa xserver git update 6 Jul 2012
Diffstat (limited to 'xorg-server/dix/touch.c')
-rw-r--r--xorg-server/dix/touch.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/xorg-server/dix/touch.c b/xorg-server/dix/touch.c
index a01f152cd..497ad7dac 100644
--- a/xorg-server/dix/touch.c
+++ b/xorg-server/dix/touch.c
@@ -160,11 +160,13 @@ TouchBeginDDXTouch(DeviceIntPtr dev, uint32_t ddx_id)
int i;
TouchClassPtr t = dev->touch;
DDXTouchPointInfoPtr ti = NULL;
- Bool emulate_pointer = (t->mode == XIDirectTouch);
+ Bool emulate_pointer;
if (!t)
return NULL;
+ emulate_pointer = (t->mode == XIDirectTouch);
+
/* Look for another active touchpoint with the same DDX ID. DDX
* touchpoints must be unique. */
if (TouchFindByDDXID(dev, ddx_id, FALSE))
@@ -461,14 +463,17 @@ TouchEventHistoryPush(TouchPointInfoPtr ti, const DeviceEvent *ev)
void
TouchEventHistoryReplay(TouchPointInfoPtr ti, DeviceIntPtr dev, XID resource)
{
- InternalEvent *tel = InitEventList(GetMaximumEventsNum());
- ValuatorMask *mask = valuator_mask_new(0);
+ InternalEvent *tel;
+ ValuatorMask *mask;
int i, nev;
int flags;
if (!ti->history)
return;
+ tel = InitEventList(GetMaximumEventsNum());
+ mask = valuator_mask_new(0);
+
valuator_mask_set_double(mask, 0, ti->history[0].valuators.data[0]);
valuator_mask_set_double(mask, 1, ti->history[0].valuators.data[1]);