summaryrefslogtreecommitdiff
path: root/nuttx/arch/sim/src/up_touchscreen.c
diff options
context:
space:
mode:
authorpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2011-09-29 21:13:49 +0000
committerpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2011-09-29 21:13:49 +0000
commiteaf142837ca2b85afa7037292dc5a08c34ff8367 (patch)
treecd55f971703914c912bb0e4bddf956d06146048a /nuttx/arch/sim/src/up_touchscreen.c
parent46801bed95c44460286a1ed78fc07e813eebfb66 (diff)
downloadpx4-nuttx-eaf142837ca2b85afa7037292dc5a08c34ff8367.tar.gz
px4-nuttx-eaf142837ca2b85afa7037292dc5a08c34ff8367.tar.bz2
px4-nuttx-eaf142837ca2b85afa7037292dc5a08c34ff8367.zip
Don't run X11 event loop on a pthread; X11 is not thread-safe.
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@4001 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'nuttx/arch/sim/src/up_touchscreen.c')
-rw-r--r--nuttx/arch/sim/src/up_touchscreen.c15
1 files changed, 5 insertions, 10 deletions
diff --git a/nuttx/arch/sim/src/up_touchscreen.c b/nuttx/arch/sim/src/up_touchscreen.c
index 3765d9e6e..bc94d6056 100644
--- a/nuttx/arch/sim/src/up_touchscreen.c
+++ b/nuttx/arch/sim/src/up_touchscreen.c
@@ -661,15 +661,6 @@ int sim_tcinitialize(int minor)
priv->minor = minor;
- /* Start the X11 event loop */
-
- ret = up_x11eventloop();
- if (ret < 0)
- {
- idbg("Failed to start event loop: %d\n", ret);
- goto errout_with_priv;
- }
-
/* Register the device as an input device */
(void)snprintf(devname, DEV_NAMELEN, DEV_FORMAT, minor);
@@ -682,6 +673,10 @@ int sim_tcinitialize(int minor)
goto errout_with_priv;
}
+ /* Enable X11 event processing from the IDLE loop */
+
+ g_eventloop = 1;
+
/* And return success */
return OK;
@@ -731,7 +726,7 @@ void sim_tcuninitialize(void)
* done in close() using a reference count).
*/
- g_evloopactive = 0;
+ g_eventloop = 0;
/* Un-register the device*/