[gtk+] Add some more info for desktop app info



commit 69745041f80a579991d630a590ac8b2bae9fb757
Author: Matthias Clasen <mclasen redhat com>
Date:   Wed Feb 9 09:01:16 2011 -0500

    Add some more info for desktop app info
    
    Small gotchas that can easily be avoided.

 docs/reference/gtk/migrating-2to3.xml |    6 +++++-
 1 files changed, 5 insertions(+), 1 deletions(-)
---
diff --git a/docs/reference/gtk/migrating-2to3.xml b/docs/reference/gtk/migrating-2to3.xml
index 2b2f472..915ed45 100644
--- a/docs/reference/gtk/migrating-2to3.xml
+++ b/docs/reference/gtk/migrating-2to3.xml
@@ -144,7 +144,7 @@
         GAppLaunchContext *context;
         GError *error = NULL;
 
-        info = g_desktop_app_info_new ("epiphany.desktop");
+        info = (GAppInfo *) g_desktop_app_info_new ("epiphany.desktop");
         context = gdk_display_get_app_launch_context (display);
         g_app_info_launch (info, NULL, context, &amp;error);
 
@@ -157,6 +157,10 @@
         g_object_unref (info);
         g_object_unref (context);
         </programlisting></informalexample>
+        Remember that you have to include
+        <filename>gio/gdesktopappinfo.h</filename>
+        and use the <filename>gio-unix-2.0</filename> pkg-config file
+        when using g_desktop_app_info_new().
         </listitem>
         <listitem>If you are launching a custom commandline, you can
         still use g_app_info_launch() with a GAppInfo that is constructed



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]