diff options
author | Jeffrey Stedfast <fejj@ximian.com> | 2002-01-29 08:43:49 +0800 |
---|---|---|
committer | Jeffrey Stedfast <fejj@src.gnome.org> | 2002-01-29 08:43:49 +0800 |
commit | 2f904b426ce0b24a9b0893e6051058b5304c05b3 (patch) | |
tree | ad7bd88dcf48274fe323386c570e99c16696c248 /mail | |
parent | aeb798c02882fb8198f9ecc948415be00db30b73 (diff) | |
download | gsoc2013-evolution-2f904b426ce0b24a9b0893e6051058b5304c05b3.tar gsoc2013-evolution-2f904b426ce0b24a9b0893e6051058b5304c05b3.tar.gz gsoc2013-evolution-2f904b426ce0b24a9b0893e6051058b5304c05b3.tar.bz2 gsoc2013-evolution-2f904b426ce0b24a9b0893e6051058b5304c05b3.tar.lz gsoc2013-evolution-2f904b426ce0b24a9b0893e6051058b5304c05b3.tar.xz gsoc2013-evolution-2f904b426ce0b24a9b0893e6051058b5304c05b3.tar.zst gsoc2013-evolution-2f904b426ce0b24a9b0893e6051058b5304c05b3.zip |
Don't bother checking for invalid recipients anymore. If a recipient is
2002-01-28 Jeffrey Stedfast <fejj@ximian.com>
* mail-callbacks.c (composer_get_message): Don't bother checking
for invalid recipients anymore. If a recipient is invalid, the
transport error message will specify that now.
svn path=/trunk/; revision=15501
Diffstat (limited to 'mail')
-rw-r--r-- | mail/ChangeLog | 6 | ||||
-rw-r--r-- | mail/mail-callbacks.c | 47 |
2 files changed, 12 insertions, 41 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog index a6b603bfad..23402a11fe 100644 --- a/mail/ChangeLog +++ b/mail/ChangeLog @@ -1,3 +1,9 @@ +2002-01-28 Jeffrey Stedfast <fejj@ximian.com> + + * mail-callbacks.c (composer_get_message): Don't bother checking + for invalid recipients anymore. If a recipient is invalid, the + transport error message will specify that now. + 2002-01-28 Radek Doulik <rodo@ximian.com> * mail-callbacks.c (do_mail_print): print footer diff --git a/mail/mail-callbacks.c b/mail/mail-callbacks.c index aaace95384..3358ffc6d4 100644 --- a/mail/mail-callbacks.c +++ b/mail/mail-callbacks.c @@ -401,9 +401,9 @@ composer_get_message (EMsgComposer *composer) const CamelInternetAddress *iaddr; const MailConfigAccount *account; CamelMimeMessage *message; + EDestination **recipients; const char *subject; int num_addrs, i; - EDestination **recipients; message = e_msg_composer_get_message (composer); if (message == NULL) @@ -444,45 +444,9 @@ composer_get_message (EMsgComposer *composer) } } + /* get the message recipients */ recipients = e_msg_composer_get_recipients (composer); - /* Check for invalid recipients */ - if (recipients) { - gboolean have_invalid = FALSE; - char *msg, *new_msg; - GtkWidget *message_box; - - for (i = 0; recipients[i] && !have_invalid; ++i) { - if (!e_destination_is_valid (recipients[i])) - have_invalid = TRUE; - } - - if (have_invalid) { - msg = g_strdup (_("This message contains invalid recipients:")); - for (i = 0; recipients[i]; ++i) { - if (!e_destination_is_valid (recipients[i])) { - new_msg = g_strdup_printf ("%s\n %s", msg, - e_destination_get_address (recipients[i])); - g_free (msg); - msg = new_msg; - } - } - - new_msg = e_utf8_from_locale_string (msg); - g_free (msg); - msg = new_msg; - - message_box = gnome_message_box_new (msg, GNOME_MESSAGE_BOX_WARNING, GNOME_STOCK_BUTTON_OK, NULL); - g_free (msg); - - gnome_dialog_run_and_close (GNOME_DIALOG (message_box)); - - camel_object_unref (CAMEL_OBJECT (message)); - message = NULL; - goto finished; - } - } - /* Check for recipients */ for (num_addrs = 0, i = 0; i < 3; i++) { iaddr = camel_mime_message_get_recipients (message, recipient_type[i]); @@ -537,12 +501,12 @@ composer_get_message (EMsgComposer *composer) && mail_config_get_confirm_unwanted_html ()) { gboolean html_problem = FALSE; for (i = 0; recipients[i] != NULL && !html_problem; ++i) { - if (! e_destination_get_html_mail_pref (recipients[i])) + if (!e_destination_get_html_mail_pref (recipients[i])) html_problem = TRUE; } if (html_problem) { - html_problem = ! ask_confirm_for_unwanted_html_mail (composer, recipients); + html_problem = !ask_confirm_for_unwanted_html_mail (composer, recipients); if (html_problem) { camel_object_unref (CAMEL_OBJECT (message)); message = NULL; @@ -562,11 +526,12 @@ composer_get_message (EMsgComposer *composer) } /* Get the message recipients and 'touch' them, boosting their use scores */ - recipients = e_msg_composer_get_recipients (composer); e_destination_touchv (recipients); finished: + e_destination_freev (recipients); + return message; } |