[gtranslator] Do not use gdk_spawns_* deprecated methods.



commit ef9eb2c76a9a095484a0d55ce1779d8d877977b6
Author: Hamish Morrison <hamish lavabit com>
Date:   Wed Jan 12 01:02:10 2011 +0100

    Do not use gdk_spawns_* deprecated methods.

 plugins/codeview/gtr-codeview-plugin.c |    5 +----
 src/gtr-utils.c                        |    4 +---
 2 files changed, 2 insertions(+), 7 deletions(-)
---
diff --git a/plugins/codeview/gtr-codeview-plugin.c b/plugins/codeview/gtr-codeview-plugin.c
index 19b1d89..bc5b55f 100644
--- a/plugins/codeview/gtr-codeview-plugin.c
+++ b/plugins/codeview/gtr-codeview-plugin.c
@@ -130,10 +130,7 @@ show_in_editor (const gchar * program_name,
   open[2] = g_strdup_printf ("%s%d", line_cmd, line);
   open[3] = NULL;
 
-  gdk_spawn_on_screen (gdk_screen_get_default (),
-                       NULL,
-                       open,
-                       NULL, G_SPAWN_SEARCH_PATH, NULL, NULL, NULL, NULL);
+  g_spawn_async (NULL, open, NULL, G_SPAWN_SEARCH_PATH, NULL, NULL, NULL, NULL);
   g_free (open[0]);
   g_free (open[1]);
   g_free (open[2]);
diff --git a/src/gtr-utils.c b/src/gtr-utils.c
index 7837326..4a7d61d 100644
--- a/src/gtr-utils.c
+++ b/src/gtr-utils.c
@@ -693,7 +693,6 @@ gtr_utils_help_display (GtkWindow * parent,
 {
 
   GError *error = NULL;
-  GdkScreen *screen;
   gchar *command;
   const gchar *lang;
   const gchar *const *langs;
@@ -760,8 +759,7 @@ gtr_utils_help_display (GtkWindow * parent,
   command = g_strconcat ("gnome-help ghelp://", uri, NULL);
   g_free (uri);
 
-  screen = gtk_widget_get_screen (GTK_WIDGET (parent));
-  gdk_spawn_command_line_on_screen (screen, command, &error);
+  g_spawn_command_line_async (command, &error);
 
 
   if (error != NULL)



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