#include "customheader.h"
#include "prefs_common.h"
#include "prefs_account.h"
+#include "prefs_actions.h"
#include "account.h"
#include "filesel.h"
#include "procheader.h"
#include "template.h"
#include "undo.h"
#include "foldersel.h"
-#include "prefs_actions.h"
#if USE_GPGME
# include "rfc2015.h"
{N_("/_Message/_Encrypt"), NULL, compose_toggle_encrypt_cb, 0, "<ToggleItem>"},
#endif /* USE_GPGME */
{N_("/_Message/---"), NULL, NULL, 0, "<Separator>"},
- {N_("/_Message/Priority"), NULL, NULL, 0, "<Branch>"},
- {N_("/_Message/Priority/Highest"), NULL, compose_set_priority_cb, PRIORITY_HIGHEST, "<RadioItem>"},
- {N_("/_Message/Priority/High"), NULL, compose_set_priority_cb, PRIORITY_HIGH, "/Message/Priority/Highest"},
- {N_("/_Message/Priority/Normal"), NULL, compose_set_priority_cb, PRIORITY_NORMAL, "/Message/Priority/Highest"},
- {N_("/_Message/Priority/Low"), NULL, compose_set_priority_cb, PRIORITY_LOW, "/Message/Priority/Highest"},
- {N_("/_Message/Priority/Lowest"), NULL, compose_set_priority_cb, PRIORITY_LOWEST, "/Message/Priority/Highest"},
+ {N_("/_Message/_Priority"), NULL, NULL, 0, "<Branch>"},
+ {N_("/_Message/Priority/_Highest"), NULL, compose_set_priority_cb, PRIORITY_HIGHEST, "<RadioItem>"},
+ {N_("/_Message/Priority/Hi_gh"), NULL, compose_set_priority_cb, PRIORITY_HIGH, "/Message/Priority/Highest"},
+ {N_("/_Message/Priority/_Normal"), NULL, compose_set_priority_cb, PRIORITY_NORMAL, "/Message/Priority/Highest"},
+ {N_("/_Message/Priority/Lo_w"), NULL, compose_set_priority_cb, PRIORITY_LOW, "/Message/Priority/Highest"},
+ {N_("/_Message/Priority/_Lowest"), NULL, compose_set_priority_cb, PRIORITY_LOWEST, "/Message/Priority/Highest"},
{N_("/_Message/---"), NULL, NULL, 0, "<Separator>"},
{N_("/_Message/_Request Return Receipt"), NULL, compose_toggle_return_receipt_cb, 0, "<ToggleItem>"},
{N_("/_Tools"), NULL, NULL, 0, "<Branch>"},
} else
reply_account = account;
- MSG_UNSET_PERM_FLAGS(msginfo->flags, MSG_FORWARDED);
- MSG_SET_PERM_FLAGS(msginfo->flags, MSG_REPLIED);
- if (MSG_IS_IMAP(msginfo->flags))
- imap_msg_set_perm_flags(msginfo, MSG_REPLIED);
- CHANGE_FLAGS(msginfo);
-
compose = compose_create(account, COMPOSE_REPLY);
- compose->replyinfo = procmsg_msginfo_copy(msginfo);
+ compose->replyinfo = procmsg_msginfo_new_ref(msginfo);
#if 0 /* NEW COMPOSE GUI */
if (followup_and_reply_to) {
for(list = compose->header_list; list; list = list->next) {
gchar *header;
gchar *entry;
- header = gtk_entry_get_text(GTK_ENTRY(GTK_COMBO(((ComposeHeaderEntry *)list->data)->combo)->entry));
+ header = gtk_editable_get_chars(GTK_EDITABLE(GTK_COMBO(((ComposeHeaderEntry *)list->data)->combo)->entry), 0, -1);
entry = gtk_editable_get_chars(GTK_EDITABLE(((ComposeHeaderEntry *)list->data)->entry), 0, -1);
g_strstrip(entry);
if(entry[0] != '\0') {
}
}
}
+ g_free(header);
g_free(entry);
}
return recipient_found;
for (i = 0; i < len; i += B64_LINE_SIZE) {
l = MIN(B64_LINE_SIZE, len - i);
- to64frombits(outbuf, buf + i, l);
+ base64_encode(outbuf, buf + i, l);
fputs(outbuf, fp);
fputc('\n', fp);
}
}
/* Save copy folder */
if(gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(compose->savemsg_checkbtn))) {
- gchar *str;
+ gchar *savefolderid;
+
+ savefolderid = gtk_editable_get_chars(GTK_EDITABLE(compose->savemsg_entry), 0, -1);
+ fprintf(fp, "SCF:%s\n", savefolderid);
+ g_free(savefolderid);
+ }
+ /* Message-ID of message replying to */
+ if((compose->replyinfo != NULL) && (compose->replyinfo->msgid != NULL)) {
+ gchar *folderid;
- str = gtk_editable_get_chars(GTK_EDITABLE(compose->savemsg_entry), 0, -1);
- fprintf(fp, "SCF:%s\n", str);
- g_free(str);
+ folderid = folder_item_get_identifier(compose->replyinfo->folder);
+ fprintf(fp, "RMID:%s\x7f%d\x7f%s\n", folderid, compose->replyinfo->msgnum, compose->replyinfo->msgid);
+ g_free(folderid);
}
fprintf(fp, "\n");
while ((len = fread(inbuf, sizeof(gchar),
B64_LINE_SIZE, attach_fp))
== B64_LINE_SIZE) {
- to64frombits(outbuf, inbuf, B64_LINE_SIZE);
+ base64_encode(outbuf, inbuf, B64_LINE_SIZE);
fputs(outbuf, fp);
fputc('\n', fp);
}
if (len > 0 && feof(attach_fp)) {
- to64frombits(outbuf, inbuf, len);
+ base64_encode(outbuf, inbuf, len);
fputs(outbuf, fp);
fputc('\n', fp);
}
GtkWidget *menuitem;
if (!gtkpspell_set_sug_mode(gtkpspell, prefs_common.pspell_sugmode)) {
- debug_print(_("Pspell: could not set suggestion mode %s"),
+ debug_print(_("Pspell: could not set suggestion mode %s\n"),
gtkpspellcheckers->error_message);
gtkpspell_checkers_reset_error();
}