gnome-games r7983 - trunk/aisleriot



Author: chpe
Date: Wed Oct  8 20:02:10 2008
New Revision: 7983
URL: http://svn.gnome.org/viewvc/gnome-games?rev=7983&view=rev

Log:
Also implement email hook for the about dialogue.

Modified:
   trunk/aisleriot/sol.c

Modified: trunk/aisleriot/sol.c
==============================================================================
--- trunk/aisleriot/sol.c	(original)
+++ trunk/aisleriot/sol.c	Wed Oct  8 20:02:10 2008
@@ -132,6 +132,21 @@
 #endif /* HAVE_MAEMO */
 }
 
+static void
+about_email_hook (GtkAboutDialog *about,
+                  const char *email_address,
+                  gpointer user_data)
+{
+  char *escaped, *uri;
+
+  escaped = g_uri_escape_string (email_address, NULL, FALSE);
+  uri = g_strdup_printf ("mailto:%s";, escaped);
+  g_free (escaped);
+
+  about_url_hook (about, uri, user_data);
+  g_free (uri);
+}
+
 static char *
 variation_to_game_file (const char *variation)
 {
@@ -570,6 +585,7 @@
   aisleriot_util_set_help_func (help_hook, &data);
 
   gtk_about_dialog_set_url_hook (about_url_hook, &data, NULL);
+  gtk_about_dialog_set_email_hook (about_email_hook, &data, NULL);
 
   data.window = AISLERIOT_WINDOW (aisleriot_window_new ());
   g_signal_connect (data.window, "destroy",



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