aboutsummaryrefslogtreecommitdiffstats
path: root/mail/em-composer-utils.c
diff options
context:
space:
mode:
authorNot Zed <NotZed@Ximian.com>2003-12-02 13:16:22 +0800
committerMichael Zucci <zucchi@src.gnome.org>2003-12-02 13:16:22 +0800
commit62b482ca293ced476d6f682bd03e34139f4ff5b1 (patch)
treec128dc2593b9b32cfaab2888bdabce9002884b59 /mail/em-composer-utils.c
parent4edfed50a633c889bba97732920760b54279a87e (diff)
downloadgsoc2013-evolution-62b482ca293ced476d6f682bd03e34139f4ff5b1.tar
gsoc2013-evolution-62b482ca293ced476d6f682bd03e34139f4ff5b1.tar.gz
gsoc2013-evolution-62b482ca293ced476d6f682bd03e34139f4ff5b1.tar.bz2
gsoc2013-evolution-62b482ca293ced476d6f682bd03e34139f4ff5b1.tar.lz
gsoc2013-evolution-62b482ca293ced476d6f682bd03e34139f4ff5b1.tar.xz
gsoc2013-evolution-62b482ca293ced476d6f682bd03e34139f4ff5b1.tar.zst
gsoc2013-evolution-62b482ca293ced476d6f682bd03e34139f4ff5b1.zip
Added empty_trash prompt key.
2003-12-02 Not Zed <NotZed@Ximian.com> * evolution-mail.schemas: Added empty_trash prompt key. * em-utils.c (em_utils_prompt_user): changed to take the gconf 'prompt again' key directly. Fixed callers. (em_utils_expunge_folder): prompt the user with an expunge specific message. (em_utils_empty_trash): have an empty-trash specific message for prompting confirm. (emu_confirm_expunge): removed, no longer needed. Bug #38613. (em_utils_expunge_folder): remove most line feeds, let the label wrap them. (em_utils_empty_trash): ditto. * em-subscribe-editor.c (sub_folder_subscribed): update the ui selection state after we're done. maybe we should listen on the model but this is easier. Bug #50861. * em-message-browser.c (emmb_activate): hook up our own verb list. (emmb_message_verbs[], emmb_close): implement the close verb. Bug #51558. * em-format-html-display.c (efhd_attachment_popup): duh, actually add the menu list we create. Bug #49902. * em-format.c (d): turn off debug, committed by accident. svn path=/trunk/; revision=23562
Diffstat (limited to 'mail/em-composer-utils.c')
-rw-r--r--mail/em-composer-utils.c60
1 files changed, 16 insertions, 44 deletions
diff --git a/mail/em-composer-utils.c b/mail/em-composer-utils.c
index f64ecee5dd..bc076a7f77 100644
--- a/mail/em-composer-utils.c
+++ b/mail/em-composer-utils.c
@@ -103,19 +103,11 @@ composer_destroy_cb (gpointer user_data, GObject *deadbeef)
static gboolean
ask_confirm_for_unwanted_html_mail (EMsgComposer *composer, EABDestination **recipients)
{
- gboolean show_again, res;
- GConfClient *gconf;
+ gboolean res;
GString *str;
int i;
- gconf = mail_config_get_gconf_client ();
-
- if (!gconf_client_get_bool (gconf, "/apps/evolution/mail/prompts/unwanted_html", NULL))
- return TRUE;
-
- /* FIXME: this wording sucks */
- str = g_string_new (_("You are sending an HTML-formatted message. Please make sure that\n"
- "the following recipients are willing and able to receive HTML mail:\n"));
+ str = g_string_new("");
for (i = 0; recipients[i] != NULL; ++i) {
if (!eab_destination_get_html_mail_pref (recipients[i])) {
const char *name;
@@ -125,33 +117,24 @@ ask_confirm_for_unwanted_html_mail (EMsgComposer *composer, EABDestination **rec
g_string_append_printf (str, " %s\n", name);
}
}
-
- g_string_append (str, _("Send anyway?"));
- res = em_utils_prompt_user ((GtkWindow *) composer, GTK_RESPONSE_YES, &show_again, "%s", str->str);
+
+ /* FIXME: this wording sucks */
+ res = em_utils_prompt_user((GtkWindow *) composer, GTK_RESPONSE_YES, "/apps/evolution/mail/prompts/unwanted_html",
+ _("You are sending an HTML-formatted message. Please make sure that\n"
+ "the following recipients are willing and able to receive HTML mail:\n"
+ "%s"
+ "Send anyway?"),
+ str->str);
g_string_free (str, TRUE);
- gconf_client_set_bool (gconf, "/apps/evolution/mail/prompts/unwanted_html", show_again, NULL);
-
return res;
}
static gboolean
ask_confirm_for_empty_subject (EMsgComposer *composer)
{
- gboolean show_again, res;
- GConfClient *gconf;
-
- gconf = mail_config_get_gconf_client ();
-
- if (!gconf_client_get_bool (gconf, "/apps/evolution/mail/prompts/empty_subject", NULL))
- return TRUE;
-
- res = em_utils_prompt_user ((GtkWindow *) composer, GTK_RESPONSE_YES, &show_again,
+ return em_utils_prompt_user((GtkWindow *)composer, GTK_RESPONSE_YES, "/apps/evolution/mail/prompts/empty_subject",
_("This message has no subject.\nReally send?"));
-
- gconf_client_set_bool (gconf, "/apps/evolution/mail/prompts/empty_subject", show_again, NULL);
-
- return res;
}
static gboolean
@@ -159,12 +142,6 @@ ask_confirm_for_only_bcc (EMsgComposer *composer, gboolean hidden_list_case)
{
gboolean show_again, res;
const char *first_text;
- GConfClient *gconf;
-
- gconf = mail_config_get_gconf_client ();
-
- if (!gconf_client_get_bool (gconf, "/apps/evolution/mail/prompts/only_bcc", NULL))
- return TRUE;
/* If the user is mailing a hidden contact list, it is possible for
them to create a message with only Bcc recipients without really
@@ -179,17 +156,12 @@ ask_confirm_for_only_bcc (EMsgComposer *composer, gboolean hidden_list_case)
} else {
first_text = _("This message contains only Bcc recipients.");
}
-
- res = em_utils_prompt_user ((GtkWindow *) composer, GTK_RESPONSE_YES, &show_again,
- "%s\n%s", first_text,
- _("It is possible that the mail server may reveal the recipients "
- "by adding an Apparently-To header.\nSend anyway?"));
-
- gconf_client_set_bool (gconf, "/apps/evolution/mail/prompts/only_bcc", show_again, NULL);
-
- return res;
-}
+ return em_utils_prompt_user ((GtkWindow *) composer, GTK_RESPONSE_YES, "/apps/evolution/mail/prompts/only_bcc",
+ "%s\n%s", first_text,
+ _("It is possible that the mail server may reveal the recipients "
+ "by adding an Apparently-To header.\nSend anyway?"));
+}
struct _send_data {
struct emcs_t *emcs;