diff options
author | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2011-09-29 20:54:23 +0000 |
---|---|---|
committer | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2011-09-29 20:54:23 +0000 |
commit | 46801bed95c44460286a1ed78fc07e813eebfb66 (patch) | |
tree | e2de3c36d98c8fe80ee1c1c76def082c0c68e95d /nuttx/arch/sim/src/up_touchscreen.c | |
parent | fe71dddb9c1711ed8109fd3aa013a898b0d6fede (diff) | |
download | px4-nuttx-46801bed95c44460286a1ed78fc07e813eebfb66.tar.gz px4-nuttx-46801bed95c44460286a1ed78fc07e813eebfb66.tar.bz2 px4-nuttx-46801bed95c44460286a1ed78fc07e813eebfb66.zip |
Use XGrapButton, not XGrabPointer
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@4000 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'nuttx/arch/sim/src/up_touchscreen.c')
-rw-r--r-- | nuttx/arch/sim/src/up_touchscreen.c | 41 |
1 files changed, 2 insertions, 39 deletions
diff --git a/nuttx/arch/sim/src/up_touchscreen.c b/nuttx/arch/sim/src/up_touchscreen.c index ecbe61b36..3765d9e6e 100644 --- a/nuttx/arch/sim/src/up_touchscreen.c +++ b/nuttx/arch/sim/src/up_touchscreen.c @@ -751,10 +751,10 @@ void sim_tcuninitialize(void) } /**************************************************************************** - * Name: up_tcenter + * Name: up_buttonevent ****************************************************************************/ -int up_tcenter(int x, int y, int buttons) +int up_buttonevent(int x, int y, int buttons) { FAR struct up_dev_s *priv = (FAR struct up_dev_s *)&g_simtouchscreen; bool pendown; /* true: pen is down */ @@ -815,40 +815,3 @@ int up_tcenter(int x, int y, int buttons) return OK; } -/**************************************************************************** - * Name: up_tcleave - ****************************************************************************/ - -int up_tcleave(int x, int y, int buttons) -{ - FAR struct up_dev_s *priv = (FAR struct up_dev_s *)&g_simtouchscreen; - - ivdbg("x=%d y=%d buttons=%02x\n", x, y, buttons); - ivdbg("contact=%d nwaiters=%d\n", priv->sample.contact, priv->nwaiters); - - /* Treat leaving the window as penup */ - - /* Ignore the pen up if the pen was already up (CONTACT_NONE == pen up and - * already reported. CONTACT_UP == pen up, but not reported) - */ - - if (priv->sample.contact != CONTACT_NONE) - { - priv->sample.contact = CONTACT_UP; - - /* Is there a thread waiting for the touchpad event? If so, awaken it! */ - - if (priv->nwaiters > 0) - { - /* Indicate the availability of new sample data for this ID */ - - priv->sample.id = priv->id; - priv->penchange = true; - - /* Notify any waiters that new touchscreen data is available */ - - up_notify(priv); - } - } - return OK; -} |