[clutter] docs: Include test-threads.c in the API reference
- From: Emmanuele Bassi <ebassi src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [clutter] docs: Include test-threads.c in the API reference
- Date: Thu, 13 Oct 2011 09:43:39 +0000 (UTC)
commit ef1a3a5477706126334aa9bd51b5db2f2d9f7abe
Author: Emmanuele Bassi <ebassi gnome org>
Date: Thu Oct 13 10:42:30 2011 +0100
docs: Include test-threads.c in the API reference
We can use the test-threads.c interactive test as part of the documentation
on how to use threads with Clutter.
clutter/clutter-main.c | 10 ++++++++++
1 files changed, 10 insertions(+), 0 deletions(-)
---
diff --git a/clutter/clutter-main.c b/clutter/clutter-main.c
index a6e5f4c..41f9393 100644
--- a/clutter/clutter-main.c
+++ b/clutter/clutter-main.c
@@ -77,6 +77,16 @@
* g_timeout_add() that acquire the Clutter lock before invoking the provided
* callback: clutter_threads_add_idle() and
* clutter_threads_add_timeout().</para>
+ * <para>The example below shows how to use a worker thread to perform a
+ * blocking operation, and perform UI updates using the main loop.</para>
+ * <example id="worker-thread-example">
+ * <title>A worker thread example</title>
+ * <programlisting>
+ * <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" parse="text" href="../../../../tests/interactive/test-thread.c">
+ * <xi:fallback>FIXME: MISSING XINCLUDE CONTENT</xi:fallback>
+ * </xi:include>
+ * </programlisting>
+ * </example>
* </refsect2>
*/
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]