From 397a851038f09c2a40ac70f8dbf04308622c2c02 Mon Sep 17 00:00:00 2001 From: Dan Winship Date: Thu, 27 Apr 2000 19:03:54 +0000 Subject: Move text_to_html to e-util. * mail-format.c: Move text_to_html to e-util. * mail-ops.c (send_to_url): New routine. Thin wrapper for e_msg_composer_new_from_url. * mail-display.c (on_link_clicked): print a warning for news or nntp URLs (which we'll deal with some day), and call send_to_url for mailto URLs. svn path=/trunk/; revision=2664 --- mail/mail-display.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'mail/mail-display.c') diff --git a/mail/mail-display.c b/mail/mail-display.c index d7ba658241..036ebad60b 100644 --- a/mail/mail-display.c +++ b/mail/mail-display.c @@ -13,6 +13,7 @@ #include "e-util/e-util.h" #include "mail-display.h" #include "mail-format.h" +#include "mail-ops.h" #define PARENT_TYPE (gtk_vbox_get_type ()) @@ -37,7 +38,13 @@ cid_stream (const char *cid, CamelMimeMessage *message) static void on_link_clicked (GtkHTML *html, const char *url, gpointer user_data) { - gnome_url_show (url); + if (!strncasecmp (url, "news:", 5) || + !strncasecmp (url, "nntp:", 5)) + g_warning ("Can't handle news URLs yet."); + else if (!strncasecmp (url, "mailto:", 7)) + send_to_url (url); + else + gnome_url_show (url); } static void -- cgit v1.2.3