+2002-09-26
+
+ * src/compose.[ch]: compose_reply(): added a flag for reply-to-ML.
+ compose_parse_header(): parse also List-Post header.
+ compose_reply_set_entry(): support reply-to-ML (fall back to
+ normal reply if ML address is not found).
+ * src/mainwindow.c
+ src/prefs_common.c
+ src/summaryview.c: reorganized Reply menu and added 'Reply to
+ mailing list'.
+ * src/utils.[ch]: scan_mailto_url(): new. It scans mailto URL and
+ returns newly allocated parameters.
+
2002-09-25
* src/account.c: account_read_config_all(): set account information
+2002-09-26 [paul] 0.8.3claws25
+
+ * sync with 0.8.3cvs7
+ see ChangeLog 2002-09-26
+
2002-09-26 [paul] 0.8.3claws24
* sync with 0.8.3cvs6
+2002-09-26
+
+ * src/compose.[ch]: compose_reply(): ML ¤Ø¤ÎÊÖ¿®ÍѤΥե饰¤òÄɲá£
+ compose_parse_header(): List-Post ¥Ø¥Ã¥À¤â¥Ñ¡¼¥¹¡£
+ compose_reply_set_entry(): ML ¤Ø¤ÎÊÖ¿®¤ËÂбþ(ML ¤Î¥¢¥É¥ì¥¹¤¬
+ ¸«¤Ä¤«¤é¤Ê¤±¤ì¤ÐÄ̾ï¤ÎÊÖ¿®¤Ë fallback ¤¹¤ë)¡£
+ * src/mainwindow.c
+ src/prefs_common.c
+ src/summaryview.c: ÊÖ¿®¥á¥Ë¥å¡¼¤òºÆ¹½À®¤·¡¢¡Ö¥á¡¼¥ê¥ó¥°¥ê¥¹¥È¤Ë
+ ÊÖ¿®¡×¤òÄɲá£
+ * src/utils.[ch]: scan_mailto_url(): ¿·µ¬¡£ mailto URL ¤ò¥¹¥¥ã¥ó¤·¡¢
+ ¿·µ¬¤Ë³ÎÊݤ·¤¿¥Ñ¥é¥á¡¼¥¿¤òÊÖ¤¹¡£
+
2002-09-25
* src/account.c: account_read_config_all(): ¥¢¥«¥¦¥ó¥È¾ðÊó¤òÀßÄê
MICRO_VERSION=3
INTERFACE_AGE=0
BINARY_AGE=0
-EXTRA_VERSION=claws24
+EXTRA_VERSION=claws25
VERSION=$MAJOR_VERSION.$MINOR_VERSION.$MICRO_VERSION$EXTRA_VERSION
dnl set $target
static void compose_reply_set_entry (Compose *compose,
MsgInfo *msginfo,
gboolean to_all,
+ gboolean to_ml,
gboolean to_sender,
gboolean
followup_and_reply_to);
gint *position,
Compose *compose);
static void compose_generic_reply(MsgInfo *msginfo, gboolean quote,
- gboolean to_all,
+ gboolean to_all, gboolean to_ml,
gboolean ignore_replyto,
gboolean followup_and_reply_to,
const gchar *body);
*/
void compose_reply(MsgInfo *msginfo, gboolean quote, gboolean to_all,
- gboolean ignore_replyto, const gchar *body)
+ gboolean to_ml, gboolean ignore_replyto,
+ const gchar *body)
{
- compose_generic_reply(msginfo, quote, to_all, ignore_replyto, FALSE,
- body);
+ compose_generic_reply(msginfo, quote, to_all, to_ml,
+ ignore_replyto, FALSE, body);
}
void compose_followup_and_reply_to(MsgInfo *msginfo, gboolean quote,
gboolean ignore_replyto,
const gchar *body)
{
- compose_generic_reply(msginfo, quote, to_all, ignore_replyto, TRUE,
- body);
+ compose_generic_reply(msginfo, quote, to_all, FALSE,
+ ignore_replyto, TRUE, body);
}
static void compose_generic_reply(MsgInfo *msginfo, gboolean quote,
- gboolean to_all,
+ gboolean to_all, gboolean to_ml,
gboolean ignore_replyto,
gboolean followup_and_reply_to,
const gchar *body)
}
if (compose_parse_header(compose, msginfo) < 0) return;
- compose_reply_set_entry(compose, msginfo, to_all, ignore_replyto,
- followup_and_reply_to);
+ compose_reply_set_entry(compose, msginfo, to_all, to_ml,
+ ignore_replyto, followup_and_reply_to);
compose_show_first_last_header(compose, TRUE);
text = GTK_STEXT(compose->text);
static void compose_entries_set(Compose *compose, const gchar *mailto)
{
- gchar *subject = NULL;
gchar *to = NULL;
gchar *cc = NULL;
gchar *bcc = NULL;
+ gchar *subject = NULL;
gchar *body = NULL;
- gchar *p;
- gchar *tmp_mailto;
-
- Xstrdup_a(tmp_mailto, mailto, return);
-
- to = tmp_mailto;
-
- p = strchr(tmp_mailto, '?');
- if (p) {
- *p = '\0';
- p++;
- }
-
- while (p) {
- gchar *field, *value;
-
- field = p;
-
- p = strchr(p, '=');
- if (!p) break;
- *p = '\0';
- p++;
- value = p;
-
- p = strchr(p, '&');
- if (p) {
- *p = '\0';
- p++;
- }
-
- if (*value == '\0') continue;
-
- if (!g_strcasecmp(field, "subject")) {
- Xalloca(subject, strlen(value) + 1, return);
- decode_uri(subject, value);
- } else if (!g_strcasecmp(field, "cc")) {
- cc = value;
- } else if (!g_strcasecmp(field, "bcc")) {
- bcc = value;
- } else if (!g_strcasecmp(field, "body")) {
- Xalloca(body, strlen(value) + 1, return);
- decode_uri(body, value);
- }
- }
+ scan_mailto_url(mailto, &to, &cc, &bcc, &subject, &body);
if (to)
compose_entry_append(compose, to, COMPOSE_TO);
- if (subject)
- gtk_entry_set_text(GTK_ENTRY(compose->subject_entry), subject);
if (cc)
compose_entry_append(compose, cc, COMPOSE_CC);
if (bcc)
compose_entry_append(compose, bcc, COMPOSE_BCC);
+ if (subject)
+ gtk_entry_set_text(GTK_ENTRY(compose->subject_entry), subject);
if (body) {
gtk_stext_insert(GTK_STEXT(compose->text),
NULL, NULL, NULL, body, -1);
gtk_stext_insert(GTK_STEXT(compose->text),
NULL, NULL, NULL, "\n", 1);
}
+
+ g_free(to);
+ g_free(cc);
+ g_free(bcc);
+ g_free(subject);
+ g_free(body);
}
static gint compose_parse_header(Compose *compose, MsgInfo *msginfo)
{
- static HeaderEntry hentry[] = {{"Reply-To:", NULL, TRUE},
- {"Cc:", NULL, FALSE},
- {"References:", NULL, FALSE},
- {"Bcc:", NULL, FALSE},
- {"Newsgroups:", NULL, FALSE},
- {"Followup-To:", NULL, FALSE},
- {"X-Mailing-List:", NULL, FALSE},
- {"X-BeenThere:", NULL, FALSE},
- {"X-Priority:", NULL, FALSE},
- {NULL, NULL, FALSE}};
+ static HeaderEntry hentry[] = {{"Reply-To:", NULL, TRUE},
+ {"Cc:", NULL, FALSE},
+ {"References:", NULL, FALSE},
+ {"Bcc:", NULL, FALSE},
+ {"Newsgroups:", NULL, FALSE},
+ {"Followup-To:", NULL, FALSE},
+ {"List-Post:", NULL, FALSE},
+ {"X-Priority:", NULL, FALSE},
+ {NULL, NULL, FALSE}};
enum
{
- H_REPLY_TO = 0,
- H_CC = 1,
- H_REFERENCES = 2,
- H_BCC = 3,
- H_NEWSGROUPS = 4,
- H_FOLLOWUP_TO = 5,
- H_X_MAILING_LIST = 6,
- H_X_BEENTHERE = 7,
- H_X_PRIORITY = 8
+ H_REPLY_TO = 0,
+ H_CC = 1,
+ H_REFERENCES = 2,
+ H_BCC = 3,
+ H_NEWSGROUPS = 4,
+ H_FOLLOWUP_TO = 5,
+ H_LIST_POST = 6,
+ H_X_PRIORITY = 7
};
FILE *fp;
compose->cc = hentry[H_CC].body;
hentry[H_CC].body = NULL;
}
- if (hentry[H_X_MAILING_LIST].body != NULL) {
- /* this is good enough to parse debian-devel */
- gchar *buf = g_malloc(strlen(hentry[H_X_MAILING_LIST].body) + 1);
- g_return_val_if_fail(buf != NULL, -1 );
- if (1 == sscanf(hentry[H_X_MAILING_LIST].body, "<%[^>]>", buf))
- compose->mailinglist = g_strdup(buf);
- g_free(buf);
- g_free(hentry[H_X_MAILING_LIST].body);
- hentry[H_X_MAILING_LIST].body = NULL ;
- }
- if (hentry[H_X_BEENTHERE].body != NULL) {
- /* this is good enough to parse the sylpheed-claws lists */
- gchar *buf = g_malloc(strlen(hentry[H_X_BEENTHERE].body) + 1);
- g_return_val_if_fail(buf != NULL, -1 );
- if (1 == sscanf(hentry[H_X_BEENTHERE].body, "%[^>]", buf))
- compose->mailinglist = g_strdup(buf);
- g_free(buf);
- g_free(hentry[H_X_BEENTHERE].body);
- hentry[H_X_BEENTHERE].body = NULL ;
- }
if (hentry[H_REFERENCES].body != NULL) {
if (compose->mode == COMPOSE_REEDIT)
compose->references = hentry[H_REFERENCES].body;
compose->followup_to = hentry[H_FOLLOWUP_TO].body;
hentry[H_FOLLOWUP_TO].body = NULL;
}
+ if (hentry[H_LIST_POST].body != NULL) {
+ gchar *to = NULL;
+
+ extract_address(hentry[H_LIST_POST].body);
+ if (hentry[H_LIST_POST].body[0] != '\0') {
+ scan_mailto_url(hentry[H_LIST_POST].body,
+ &to, NULL, NULL, NULL, NULL);
+ if (to) {
+ g_free(compose->ml_post);
+ compose->ml_post = to;
+ }
+ }
+ g_free(hentry[H_LIST_POST].body);
+ hentry[H_LIST_POST].body = NULL;
+ }
if (compose->mode == COMPOSE_REEDIT)
if (hentry[H_X_PRIORITY].body != NULL) {
}
static void compose_reply_set_entry(Compose *compose, MsgInfo *msginfo,
- gboolean to_all, gboolean ignore_replyto,
+ gboolean to_all, gboolean to_ml,
+ gboolean ignore_replyto,
gboolean followup_and_reply_to)
{
GSList *cc_list = NULL;
g_return_if_fail(compose->account != NULL);
g_return_if_fail(msginfo != NULL);
- if ((compose->account->protocol != A_NNTP) || followup_and_reply_to)
+ if (to_ml && compose->ml_post) {
+ compose_entry_append(compose, compose->ml_post,
+ COMPOSE_TO);
+ } else if ((compose->account->protocol != A_NNTP) || followup_and_reply_to) {
compose_entry_append(compose,
((compose->replyto && !ignore_replyto)
? compose->replyto
- : (compose->mailinglist && !ignore_replyto)
- ? compose->mailinglist
: msginfo->from ? msginfo->from : ""),
COMPOSE_TO);
-
- if (compose->account->protocol == A_NNTP) {
+ } else {
if (ignore_replyto)
compose_entry_append
(compose, msginfo->from ? msginfo->from : "",
(compose,
((compose->replyto && !ignore_replyto)
? compose->replyto
- : (compose->mailinglist && !ignore_replyto)
- ? compose->mailinglist
: msginfo->from ? msginfo->from : ""),
COMPOSE_TO);
} else {
} else
gtk_entry_set_text(GTK_ENTRY(compose->subject_entry), "Re: ");
+ if (to_ml && compose->ml_post) return;
if (!to_all || compose->account->protocol == A_NNTP) return;
if (compose->replyto) {
extract_address(from);
}
- if (compose->mailinglist && from) {
- cc_list = address_list_append(cc_list, from);
- }
-
if (replyto && from)
cc_list = address_list_append(cc_list, from);
-
- if (!compose->mailinglist)
- cc_list = address_list_append(cc_list, msginfo->to);
-
+ cc_list = address_list_append(cc_list, msginfo->to);
cc_list = address_list_append(cc_list, compose->cc);
to_table = g_hash_table_new(g_str_hash, g_str_equal);
compose->replyinfo = NULL;
compose->replyto = NULL;
- compose->mailinglist = NULL;
compose->cc = NULL;
compose->bcc = NULL;
compose->followup_to = NULL;
+
+ compose->ml_post = NULL;
+
compose->inreplyto = NULL;
compose->references = NULL;
compose->msgid = NULL;
g_free(compose->newsgroups);
g_free(compose->followup_to);
+ g_free(compose->ml_post);
+
g_free(compose->inreplyto);
g_free(compose->references);
g_free(compose->msgid);
COMPOSE_REPLY_TO_ALL,
COMPOSE_REPLY_TO_ALL_WITH_QUOTE,
COMPOSE_REPLY_TO_ALL_WITHOUT_QUOTE,
+ COMPOSE_REPLY_TO_LIST,
+ COMPOSE_REPLY_TO_LIST_WITH_QUOTE,
+ COMPOSE_REPLY_TO_LIST_WITHOUT_QUOTE,
COMPOSE_FORWARD,
COMPOSE_FORWARD_AS_ATTACH,
COMPOSE_FORWARD_INLINE,
gchar *bcc;
gchar *newsgroups;
gchar *followup_to;
- gchar *mailinglist;
+
+ gchar *ml_post;
gchar *inreplyto;
gchar *references;
gboolean use_bcc;
gboolean use_replyto;
gboolean use_followupto;
- gboolean use_mailinglist;
gboolean use_attach;
/* privacy settings */
void compose_reply (MsgInfo *msginfo,
gboolean quote,
gboolean to_all,
+ gboolean to_ml,
gboolean ignore_replyto,
const gchar *body);
Compose *compose_forward (PrefsAccount *account,
{N_("/_Message/Compose a_n email message"), "<control>M", compose_mail_cb, 0, NULL},
{N_("/_Message/Compose a news message"), NULL, compose_news_cb, 0, NULL},
{N_("/_Message/_Reply"), "<control>R", reply_cb, COMPOSE_REPLY, NULL},
- {N_("/_Message/Repl_y to sender"), "<control><alt>R", reply_cb, COMPOSE_REPLY_TO_SENDER, NULL},
- {N_("/_Message/Follow-up and reply to"), NULL, reply_cb, COMPOSE_FOLLOWUP_AND_REPLY_TO, NULL},
- {N_("/_Message/Reply to a_ll"), "<shift><control>R", reply_cb, COMPOSE_REPLY_TO_ALL, NULL},
+ {N_("/_Message/Repl_y to"), NULL, NULL, 0, "<Branch>"},
+ {N_("/_Message/Repl_y to/_all"), "<shift><control>R", reply_cb, COMPOSE_REPLY_TO_ALL, NULL},
+ {N_("/_Message/Repl_y to/_sender"), NULL, reply_cb, COMPOSE_REPLY_TO_SENDER, NULL},
+ {N_("/_Message/Repl_y to/mailing _list"),
+ "<control>L", reply_cb, COMPOSE_REPLY_TO_LIST, NULL},
+ {N_("/_Message/Follow-up and reply to"),NULL, reply_cb, COMPOSE_FOLLOWUP_AND_REPLY_TO, NULL},
+ {N_("/_Message/---"), NULL, NULL, 0, "<Separator>"},
{N_("/_Message/_Forward"), "<control><alt>F", reply_cb, COMPOSE_FORWARD, NULL},
{N_("/_Message/Redirect"), NULL, reply_cb, COMPOSE_REDIRECT, NULL},
{N_("/_Message/---"), NULL, NULL, 0, "<Separator>"},
{N_("/_Tools/---"), NULL, NULL, 0, "<Separator>"},
{N_("/_Tools/E_xecute"), "X", execute_summary_cb, 0, NULL},
{N_("/_Tools/---"), NULL, NULL, 0, "<Separator>"},
- {N_("/_Tools/_Log window"), "<control>L", log_window_show_cb, 0, NULL},
+ {N_("/_Tools/_Log window"), "<shift><control>L", log_window_show_cb, 0, NULL},
{N_("/_Configuration"), NULL, NULL, 0, "<Branch>"},
{N_("/_Configuration/_Common preferences..."),
{"/Message/Cancel receiving" , M_INC_ACTIVE},
{"/Message/Compose a news message", M_HAVE_NEWS_ACCOUNT},
{"/Message/Reply" , M_HAVE_ACCOUNT|M_SINGLE_TARGET_EXIST},
- {"/Message/Reply to sender" , M_HAVE_ACCOUNT|M_SINGLE_TARGET_EXIST},
- {"/Message/Reply to all" , M_HAVE_ACCOUNT|M_SINGLE_TARGET_EXIST},
+ {"/Message/Reply to" , M_HAVE_ACCOUNT|M_SINGLE_TARGET_EXIST},
{"/Message/Follow-up and reply to", M_HAVE_ACCOUNT|M_SINGLE_TARGET_EXIST|M_NEWS},
{"/Message/Forward" , M_HAVE_ACCOUNT|M_TARGET_EXIST},
{"/Message/Redirect" , M_HAVE_ACCOUNT|M_SINGLE_TARGET_EXIST},
"(menu-path \"<Main>/Message/Get from all accounts\" \"<shift><control>I\")\n"
"(menu-path \"<Main>/Message/Compose an email message\" \"<control>M\")\n"
"(menu-path \"<Main>/Message/Reply\" \"<control>R\")\n"
- "(menu-path \"<Main>/Message/Reply to sender\" \"\")\n"
- "(menu-path \"<Main>/Message/Reply to all\" \"<shift><control>R\")\n"
+ "(menu-path \"<Main>/Message/Reply to/all\" \"<shift><control>R\")\n"
+ "(menu-path \"<Main>/Message/Reply to/sender\" \"\")\n"
+ "(menu-path \"<Main>/Message/Reply to/mailing list\" \"<control>L\")\n"
"(menu-path \"<Main>/Message/Forward\" \"<control><alt>F\")\n"
/* "(menu-path \"<Main>/Message/Forward as attachment\" \"\")\n" */
"(menu-path \"<Main>/Message/Move...\" \"<control>O\")\n"
"(menu-path \"<Main>/Tools/Address book\" \"<shift><control>A\")\n"
"(menu-path \"<Main>/Tools/Execute\" \"X\")\n"
- "(menu-path \"<Main>/Tools/Log window\" \"<control>L\")\n"
+ "(menu-path \"<Main>/Tools/Log window\" \"<shift><control>L\")\n"
"(menu-path \"<Compose>/File/Close\" \"<control>W\")\n"
"(menu-path \"<Compose>/Edit/Select all\" \"<control>A\")\n"
"(menu-path \"<Main>/Message/Get from all accounts\" \"<shift><control>I\")\n"
"(menu-path \"<Main>/Message/Compose an email message\" \"W\")\n"
"(menu-path \"<Main>/Message/Reply\" \"<control>R\")\n"
- "(menu-path \"<Main>/Message/Reply to sender\" \"\")\n"
- "(menu-path \"<Main>/Message/Reply to all\" \"<shift>A\")\n"
+ "(menu-path \"<Main>/Message/Reply to/all\" \"<shift>A\")\n"
+ "(menu-path \"<Main>/Message/Reply to/sender\" \"\")\n"
+ "(menu-path \"<Main>/Message/Reply to/mailing list\" \"<control>L\")\n"
"(menu-path \"<Main>/Message/Forward\" \"F\")\n"
/* "(menu-path \"<Main>/Message/Forward as attachment\" \"<shift>F\")\n" */
"(menu-path \"<Main>/Message/Move...\" \"O\")\n"
"(menu-path \"<Main>/Tools/Address book\" \"<shift><control>A\")\n"
"(menu-path \"<Main>/Tools/Execute\" \"X\")\n"
- "(menu-path \"<Main>/Tools/Log window\" \"<control>L\")\n"
+ "(menu-path \"<Main>/Tools/Log window\" \"<shift><control>L\")\n"
"(menu-path \"<Compose>/File/Close\" \"<alt>W\")\n"
"(menu-path \"<Compose>/Edit/Select all\" \"\")\n"
"(menu-path \"<Main>/Message/Get from all accounts\" \"<shift><control>I\")\n"
"(menu-path \"<Main>/Message/Compose new message\" \"M\")\n"
"(menu-path \"<Main>/Message/Reply\" \"R\")\n"
- "(menu-path \"<Main>/Message/Reply to all\" \"G\")\n"
- "(menu-path \"<Main>/Message/Reply to sender\" \"\")\n"
+ "(menu-path \"<Main>/Message/Reply to/all\" \"G\")\n"
+ "(menu-path \"<Main>/Message/Reply to/sender\" \"\")\n"
+ "(menu-path \"<Main>/Message/Reply to/mailing list\" \"<control>L\")\n"
"(menu-path \"<Main>/Message/Forward\" \"F\")\n"
"(menu-path \"<Main>/Message/Forward as attachment\" \"\")\n"
"(menu-path \"<Main>/Message/Move...\" \"<control>O\")\n"
"(menu-path \"<Main>/Tools/Address book\" \"<shift><control>A\")\n"
"(menu-path \"<Main>/Tools/Execute\" \"X\")\n"
- "(menu-path \"<Main>/Tools/Log window\" \"<control>L\")\n"
+ "(menu-path \"<Main>/Tools/Log window\" \"<shift><control>L\")\n"
"(menu-path \"<Compose>/File/Close\" \"<alt>W\")\n"
"(menu-path \"<Compose>/Edit/Select all\" \"\")\n"
"(menu-path \"<Main>/Message/Get from all accounts\" \"<shift><alt>I\")\n"
"(menu-path \"<Main>/Message/Compose an email message\" \"<alt>N\")\n"
"(menu-path \"<Main>/Message/Reply\" \"<alt>R\")\n"
- "(menu-path \"<Main>/Message/Reply to sender\" \"<control><alt>R\")\n"
- "(menu-path \"<Main>/Message/Reply to all\" \"<shift><alt>R\")\n"
+ "(menu-path \"<Main>/Message/Reply to/all\" \"<shift><alt>R\")\n"
+ "(menu-path \"<Main>/Message/Reply to/sender\" \"<control><alt>R\")\n"
+ "(menu-path \"<Main>/Message/Reply to/mailing list\" \"<control>L\")\n"
"(menu-path \"<Main>/Message/Forward\" \"<shift><alt>F\")\n"
/* "(menu-path \"<Main>/Message/Forward as attachment\" \"<shift><control>F\")\n" */
"(menu-path \"<Main>/Message/Move...\" \"<alt>O\")\n"
"(menu-path \"<Main>/Message/Get from all accounts\" \"\")\n"
"(menu-path \"<Main>/Message/Compose an email message\" \"\")\n"
"(menu-path \"<Main>/Message/Reply\" \"\")\n"
- "(menu-path \"<Main>/Message/Reply to sender\" \"\")\n"
- "(menu-path \"<Main>/Message/Reply to all\" \"\")\n"
+ "(menu-path \"<Main>/Message/Reply to/all\" \"\")\n"
+ "(menu-path \"<Main>/Message/Reply to/sender\" \"\")\n"
+ "(menu-path \"<Main>/Message/Reply to/mailing list\" \"\")\n"
"(menu-path \"<Main>/Message/Forward\" \"\")\n"
/* "(menu-path \"<Main>/Message/Forward as attachment\" \"\")\n" */
"(menu-path \"<Main>/Message/Move...\" \"\")\n"
static GtkItemFactoryEntry summary_popup_entries[] =
{
{N_("/_Reply"), NULL, summary_reply_cb, COMPOSE_REPLY, NULL},
- {N_("/Repl_y to sender"), NULL, summary_reply_cb, COMPOSE_REPLY_TO_SENDER, NULL},
+ {N_("/Repl_y to"), NULL, NULL, 0, "<Branch>"},
+ {N_("/Repl_y to/_all"), NULL, summary_reply_cb, COMPOSE_REPLY_TO_ALL, NULL},
+ {N_("/Repl_y to/_sender"), NULL, summary_reply_cb, COMPOSE_REPLY_TO_SENDER, NULL},
+ {N_("/Repl_y to/mailing _list"),
+ NULL, summary_reply_cb, COMPOSE_REPLY_TO_LIST, NULL},
{N_("/Follow-up and reply to"), NULL, summary_reply_cb, COMPOSE_FOLLOWUP_AND_REPLY_TO, NULL},
- {N_("/Reply to a_ll"), NULL, summary_reply_cb, COMPOSE_REPLY_TO_ALL, NULL},
+ {N_("/---"), NULL, NULL, 0, "<Separator>"},
{N_("/_Forward"), NULL, summary_reply_cb, COMPOSE_FORWARD, NULL},
{N_("/Redirect"), NULL, summary_reply_cb, COMPOSE_REDIRECT, NULL},
{N_("/---"), NULL, NULL, 0, "<Separator>"},
sens = (selection == SUMMARY_SELECTED_MULTIPLE) ? FALSE : TRUE;
menu_set_sensitive(ifactory, "/Reply", sens);
- menu_set_sensitive(ifactory, "/Reply to sender", sens);
- menu_set_sensitive(ifactory, "/Reply to all", sens);
+ menu_set_sensitive(ifactory, "/Reply to", sens);
+ menu_set_sensitive(ifactory, "/Reply to/all", sens);
+ menu_set_sensitive(ifactory, "/Reply to/sender", sens);
+ menu_set_sensitive(ifactory, "/Reply to/mailing list", sens);
menu_set_sensitive(ifactory, "/Forward", TRUE);
menu_set_sensitive(ifactory, "/Redirect", sens);
switch (mode) {
case COMPOSE_REPLY:
compose_reply(msginfo, prefs_common.reply_with_quote,
- FALSE, FALSE, text);
+ FALSE, FALSE, FALSE, text);
break;
case COMPOSE_REPLY_WITH_QUOTE:
- compose_reply(msginfo, TRUE, FALSE, FALSE, text);
+ compose_reply(msginfo, TRUE, FALSE, FALSE, FALSE, text);
break;
case COMPOSE_REPLY_WITHOUT_QUOTE:
- compose_reply(msginfo, FALSE, FALSE, FALSE, NULL);
+ compose_reply(msginfo, FALSE, FALSE, FALSE, FALSE, NULL);
break;
case COMPOSE_REPLY_TO_SENDER:
compose_reply(msginfo, prefs_common.reply_with_quote,
- FALSE, TRUE, text);
+ FALSE, FALSE, TRUE, text);
break;
case COMPOSE_FOLLOWUP_AND_REPLY_TO:
compose_followup_and_reply_to(msginfo,
FALSE, TRUE, text);
break;
case COMPOSE_REPLY_TO_SENDER_WITH_QUOTE:
- compose_reply(msginfo, TRUE, FALSE, TRUE, text);
+ compose_reply(msginfo, TRUE, FALSE, FALSE, TRUE, text);
break;
case COMPOSE_REPLY_TO_SENDER_WITHOUT_QUOTE:
- compose_reply(msginfo, FALSE, FALSE, TRUE, NULL);
+ compose_reply(msginfo, FALSE, FALSE, FALSE, TRUE, NULL);
break;
case COMPOSE_REPLY_TO_ALL:
compose_reply(msginfo, prefs_common.reply_with_quote,
- TRUE, FALSE, text);
+ TRUE, FALSE, FALSE, text);
break;
case COMPOSE_REPLY_TO_ALL_WITH_QUOTE:
- compose_reply(msginfo, TRUE, TRUE, FALSE, text);
+ compose_reply(msginfo, TRUE, TRUE, FALSE, FALSE, text);
break;
case COMPOSE_REPLY_TO_ALL_WITHOUT_QUOTE:
- compose_reply(msginfo, FALSE, TRUE, FALSE, NULL);
+ compose_reply(msginfo, FALSE, TRUE, FALSE, FALSE, NULL);
+ break;
+ case COMPOSE_REPLY_TO_LIST:
+ compose_reply(msginfo, prefs_common.reply_with_quote,
+ FALSE, TRUE, FALSE, text);
+ break;
+ case COMPOSE_REPLY_TO_LIST_WITH_QUOTE:
+ compose_reply(msginfo, TRUE, FALSE, TRUE, FALSE, text);
+ break;
+ case COMPOSE_REPLY_TO_LIST_WITHOUT_QUOTE:
+ compose_reply(msginfo, FALSE, FALSE, TRUE, FALSE, NULL);
break;
case COMPOSE_FORWARD:
if (prefs_common.forward_as_attachment) {
} \
}
+gint scan_mailto_url(const gchar *mailto, gchar **to, gchar **cc, gchar **bcc,
+ gchar **subject, gchar **body)
+{
+ gchar *tmp_mailto;
+ gchar *p;
+
+ Xstrdup_a(tmp_mailto, mailto, return -1);
+
+ if (!strncmp(tmp_mailto, "mailto:", 7))
+ tmp_mailto += 7;
+
+ p = strchr(tmp_mailto, '?');
+ if (p) {
+ *p = '\0';
+ p++;
+ }
+
+ if (to && !*to)
+ *to = g_strdup(tmp_mailto);
+
+ while (p) {
+ gchar *field, *value;
+
+ field = p;
+
+ p = strchr(p, '=');
+ if (!p) break;
+ *p = '\0';
+ p++;
+
+ value = p;
+
+ p = strchr(p, '&');
+ if (p) {
+ *p = '\0';
+ p++;
+ }
+
+ if (*value == '\0') continue;
+
+ if (cc && !*cc && !g_strcasecmp(field, "cc")) {
+ *cc = g_strdup(value);
+ } else if (bcc && !*bcc && !g_strcasecmp(field, "bcc")) {
+ *bcc = g_strdup(value);
+ } else if (subject && !*subject &&
+ !g_strcasecmp(field, "subject")) {
+ *subject = g_malloc(strlen(value) + 1);
+ decode_uri(*subject, value);
+ } else if (body && !*body && !g_strcasecmp(field, "body")) {
+ *body = g_malloc(strlen(value) + 1);
+ decode_uri(*body, value);
+ }
+ }
+
+ return 0;
+}
+
/*
* We need this wrapper around g_get_home_dir(), so that
* we can fix some Windoze things here. Should be done in glibc of course
GList *uri_list_extract_filenames (const gchar *uri_list);
void decode_uri (gchar *decoded_uri,
const gchar *encoded_uri);
+gint scan_mailto_url (const gchar *mailto,
+ gchar **to,
+ gchar **cc,
+ gchar **bcc,
+ gchar **subject,
+ gchar **body);
/* return static strings */
gchar *get_home_dir (void);