evolution r36505 - trunk/mail
- From: pwithnall svn gnome org
- To: svn-commits-list gnome org
- Subject: evolution r36505 - trunk/mail
- Date: Tue, 30 Sep 2008 19:38:49 +0000 (UTC)
Author: pwithnall
Date: Tue Sep 30 19:38:49 2008
New Revision: 36505
URL: http://svn.gnome.org/viewvc/evolution?rev=36505&view=rev
Log:
2008-09-30 Philip Withnall <philip tecnocode co uk>
** Fix for bug #545045
* mail-send-recv.c (build_dialog): Don't show SMTP in the
Send/Receive dialogue if there are no unsent mails.
Modified:
trunk/mail/ChangeLog
trunk/mail/mail-send-recv.c
Modified: trunk/mail/mail-send-recv.c
==============================================================================
--- trunk/mail/mail-send-recv.c (original)
+++ trunk/mail/mail-send-recv.c Tue Sep 30 19:38:49 2008
@@ -415,6 +415,10 @@
g_object_unref (iter);
+ /* Check to see if we have to send any mails --- if we don't, don't display the SMTP row in the table */
+ if (outbox && destination && camel_folder_get_message_count (outbox) == 0)
+ num_sources--;
+
table = gtk_table_new (num_sources, 4, FALSE);
gtk_container_set_border_width (GTK_CONTAINER (table), 6);
gtk_table_set_row_spacings (GTK_TABLE (table), 6);
@@ -539,7 +543,8 @@
target = em_event_target_new_send_receive (em_event_peek(), table, data, row, EM_EVENT_SEND_RECEIVE);
e_event_emit ((EEvent *)em_event_peek (), "mail.sendreceive", (EEventTarget *) target);
- if (outbox && destination) {
+ /* Skip displaying the SMTP row if we've got no outbox, destination or unsent mails */
+ if (outbox && destination && camel_folder_get_message_count (outbox) != 0) {
info = g_hash_table_lookup (data->active, SEND_URI_KEY);
if (info == NULL) {
info = g_malloc0 (sizeof (*info));
@@ -601,9 +606,9 @@
g_signal_connect (
cancel_button, "clicked",
G_CALLBACK (receive_cancel), info);
- gtk_widget_show_all (table);
}
+ gtk_widget_show_all (table);
gtk_widget_show (GTK_WIDGET (gd));
g_signal_connect (gd, "response", G_CALLBACK (dialog_response), data);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]