]>
Commit | Line | Data |
---|---|---|
11a46c0d MK |
1 | diff -Nuard evolution-1.4.5.orig/mail/ChangeLog evolution-1.4.5/mail/ChangeLog |
2 | --- evolution-1.4.5.orig/mail/ChangeLog 2003-09-12 20:40:39.000000000 +0200 | |
3 | +++ evolution-1.4.5/mail/ChangeLog 2003-11-24 20:44:22.421899736 +0100 | |
4 | @@ -1,3 +1,9 @@ | |
5 | +2003-11-23 Marcin Krzyzanowski <krzak@pld-linux.org> | |
6 | + | |
7 | + * mail-display.c (launch_cb): check if application launcher | |
8 | + is described that he need terminal, if yes launch GNOME | |
9 | + preffered terminal. Fixes bug #51288. | |
10 | + | |
11 | 2003-09-11 Jeffrey Stedfast <fejj@ximian.com> | |
12 | ||
13 | * mail-format.c (handle_text_plain): Don't set inend until after | |
57844866 MK |
14 | diff -Nuard evolution-1.4.5.orig/mail/mail-display.c evolution-1.4.5/mail/mail-display.c |
15 | --- evolution-1.4.5.orig/mail/mail-display.c 2003-09-11 18:20:32.000000000 +0200 | |
11a46c0d | 16 | +++ evolution-1.4.5/mail/mail-display.c 2003-11-24 20:36:45.816314336 +0100 |
57844866 MK |
17 | @@ -371,6 +371,7 @@ |
18 | GList *apps, *children, *c; | |
19 | GnomeVFSMimeApplication *app; | |
20 | char *command, *filename; | |
21 | + gchar *terminal = NULL; | |
22 | const char *tmpdir; | |
23 | ||
24 | handler = mail_lookup_handler (g_object_get_data(user_data, "mime_type")); | |
11a46c0d | 25 | @@ -419,11 +420,26 @@ |
57844866 MK |
26 | return; |
27 | } | |
28 | ||
29 | - command = g_strdup_printf ("%s %s%s &", app->command, | |
11a46c0d | 30 | + if (app->requires_terminal) { |
57844866 | 31 | + gchar *terminal_exec, *terminal_exec_arg; |
11a46c0d | 32 | + GConfClient *gconf = mail_config_get_gconf_client (); |
57844866 MK |
33 | + |
34 | + terminal_exec = gconf_client_get_string (gconf, "/desktop/gnome/applications/terminal/exec", NULL); | |
35 | + terminal_exec_arg = gconf_client_get_string (gconf, "/desktop/gnome/applications/terminal/exec_arg", NULL); | |
36 | + | |
11a46c0d | 37 | + if (terminal_exec && terminal_exec_arg) |
57844866 MK |
38 | + terminal = g_strdup_printf("%s %s",terminal_exec, terminal_exec_arg); |
39 | + | |
40 | + g_free(terminal_exec); | |
41 | + g_free(terminal_exec_arg); | |
42 | + } | |
43 | + | |
44 | + command = g_strdup_printf ("%s %s %s%s &", terminal ? terminal : "", app->command, | |
45 | app->expects_uris == GNOME_VFS_MIME_APPLICATION_ARGUMENT_TYPE_URIS ? | |
46 | "file://" : "", filename); | |
57844866 MK |
47 | + g_free (terminal); |
48 | g_free (filename); | |
49 | - | |
50 | + | |
51 | system (command); | |
52 | g_free (command); | |
53 | } |