41 {
N_(
"Exit"), OP_EXIT },
42 {
N_(
"Archive"), OP_LIST_ARCHIVE },
43 {
N_(
"Help"), OP_LIST_HELP },
44 {
N_(
"Owner"), OP_LIST_OWNER },
45 {
N_(
"Post"), OP_LIST_POST },
46 {
N_(
"Subscribe"), OP_LIST_SUBSCRIBE },
47 {
N_(
"Unsubscribe"), OP_LIST_UNSUBSCRIBE },
95 return (
char **) (((
char *) headers) + action->
offset);
150 mutt_error(
_(
"List actions only support mailto: URIs. (Try a browser?)"));
167 char ctype[] =
"text/plain";
185 fprintf(fp,
"%s\n", body);
255 if (!event || !dlg || !dlg->
wdata)
313 mutt_error(
_(
"Unable to read mailing list headers"));
340 struct KeyEvent event = { 0, OP_NULL };
size_t buf_addch(struct Buffer *buf, char c)
Add a single character to a Buffer.
size_t buf_addstr(struct Buffer *buf, const char *s)
Add a string to a Buffer.
size_t buf_strcpy(struct Buffer *buf, const char *s)
Copy a string into a Buffer.
char * buf_strdup(const struct Buffer *buf)
Copy a Buffer's string.
static const char * buf_string(const struct Buffer *buf)
Convert a buffer to a const char * "string".
Convenience wrapper for the core headers.
size_t mutt_strwidth(const char *s)
Measure a string's width in screen cells.
struct MuttWindow * dialog_find(struct MuttWindow *win)
Find the parent Dialog of a Window.
const char * dispatcher_get_retval_name(int rv)
Get the name of a return value.
void dispatcher_flush_on_error(int rv)
Flush pending keys after a dispatch error.
@ FR_SUCCESS
Valid function - successfully performed.
@ FR_UNKNOWN
Unknown function.
@ FR_ERROR
Valid function - error occurred.
@ FR_NO_ACTION
Valid function - no action performed.
static const struct Mapping ListHelp[]
Help Bar for the Mailing-list action dialog.
static int op_exit(struct ListData *ld, const struct KeyEvent *event)
Exit the list dialog.
static char ** get_action_value(struct Rfc2369ListHeaders *headers, const struct ListAction *action)
Get the stored value for a mailing-list action.
static int op_select_action(struct ListData *ld, const struct KeyEvent *event)
Execute the selected mailing-list action.
static const struct ListAction ListActions[]
Mailing-list actions shown in the dialog.
static bool compose_list_action(struct ListData *ld, const struct ListAction *action)
Compose a message for a mailing-list action.
static const struct ListFunction ListFunctions[]
Functions handled by the list dialog.
struct Body * mutt_body_new(void)
Create a new Body.
struct Email * email_new(void)
Create a new Email.
void email_free(struct Email **ptr)
Free an Email.
Structs that make up an email.
void mutt_parse_content_type(const char *s, struct Body *b)
Parse a content type.
bool mutt_parse_mailto(struct Envelope *env, char **body, const char *src)
Parse a mailto:// url.
void mutt_rfc2369_list_headers_free(struct Rfc2369ListHeaders *headers)
Free RFC 2369 mailing-list header values.
void mutt_rfc2369_read_headers(FILE *fp, struct Rfc2369ListHeaders *headers)
Read RFC 2369 mailing-list headers.
struct Envelope * mutt_env_new(void)
Create a new Envelope.
bool mutt_file_seek(FILE *fp, LOFF_T offset, int whence)
Wrapper for fseeko with error handling.
#define mutt_file_fclose(FP)
#define mutt_file_fopen(PATH, MODE)
struct KeyEvent km_dokey(const struct MenuDefinition *md, GetChFlags flags)
Determine what a keypress should do.
void km_error_key(const struct MenuDefinition *md)
Handle an unbound key sequence.
@ GETCH_NONE
No flags are set.
static int op_exit(struct AliasFunctionData *fdata, const struct KeyEvent *event)
exit this menu - Implements alias_function_t -
static int list_function_dispatcher(struct MuttWindow *win, const struct KeyEvent *event)
Perform a List dialog function - Implements function_dispatcher_t -.
int menu_tagging_dispatcher(struct MuttWindow *win, const struct KeyEvent *event)
Perform tagging operations on the Menu - Implements function_dispatcher_t -.
int global_function_dispatcher(struct MuttWindow *win, const struct KeyEvent *event)
Perform a Global function - Implements function_dispatcher_t -.
int menu_function_dispatcher(struct MuttWindow *win, const struct KeyEvent *event)
Perform a Menu function - Implements function_dispatcher_t -.
void dlg_list(struct Mailbox *m, struct Email *e)
Display mailing-list actions for an email -.
#define mutt_debug(LEVEL,...)
Convenience wrapper for the gui headers.
void simple_dialog_free(struct MuttWindow **ptr)
Destroy a simple index Dialog.
struct SimpleDialogWindows simple_dialog_new(const struct MenuDefinition *md, enum WindowType wtype, const struct Mapping *help_data)
Create a simple index Dialog.
GUI manage the main index (list of emails)
Index private Module data.
@ LL_DEBUG1
Log at debug level 1.
#define FREE(x)
Free memory and set the pointer to NULL.
#define MUTT_MEM_CALLOC(n, type)
#define MAX(a, b)
Return the maximum of two values.
@ DISP_INLINE
Content is inline.
@ MODULE_ID_INDEX
ModuleIndex, Index
Convenience wrapper for the library headers.
void mutt_clear_error(void)
Clear the message line (bottom line of screen)
void window_redraw(struct MuttWindow *win)
Reflow, recalc and repaint a tree of Windows.
struct MuttWindow * window_set_focus(struct MuttWindow *win)
Set the Window focus.
@ WT_DLG_LIST
List Dialog, dlg_list()
int mx_msg_close(struct Mailbox *m, struct Message **ptr)
Close a message.
struct Message * mx_msg_open(struct Mailbox *m, struct Email *e)
Return a stream pointer for a message.
void * neomutt_get_module_data(struct NeoMutt *n, enum ModuleId id)
Get the private data for a Module.
const char * opcodes_get_name(int op)
Get the name of an opcode.
struct Buffer * buf_pool_get(void)
Get a Buffer from the pool.
void buf_pool_release(struct Buffer **ptr)
Return a Buffer to the pool.
void sbar_set_title(struct MuttWindow *win, const char *title)
Set the title for the Simple Bar.
Convenience wrapper for the send headers.
int mutt_send_message(SendFlags flags, struct Email *e_templ, const char *tempfile, struct Mailbox *m, struct EmailArray *ea, struct ConfigSubset *sub)
Send an email.
@ SEND_DRAFT_FILE
Used by the -H flag.
bool unlink
If true, filename should be unlink()ed before free()ing this structure.
bool use_disp
Content-Disposition uses filename= ?
unsigned int disposition
content-disposition, ContentDisposition
char * filename
When sending a message, this is the file to which this structure refers.
String manipulation buffer.
The envelope/body of an email.
struct Envelope * env
Envelope information.
struct Body * body
List of MIME parts.
LOFF_T offset
Where in the stream does this message begin?
Index private Module data.
struct MenuDefinition * menu_list
Mailing-list action menu definition.
An event such as a keypress.
int op
Function opcode, e.g. OP_HELP.
A mailing-list action in the dialog.
const char * name
Label for the action.
size_t offset
Offset into struct Rfc2369ListHeaders.
Private data for the Mailing-list action dialog.
int label_width
Width of the longest action label.
struct Menu * menu
Dialog menu.
struct Mailbox * mailbox
Source mailbox.
struct Rfc2369ListHeaders headers
Parsed List-* headers.
bool done
Exit the dialog.
int(* function)(struct ListData *ld, const struct KeyEvent *event)
Function.
Mapping between user-readable string and a constant.
A local copy of an email.
FILE * fp
pointer to the message data
void * wdata
Private data.
Container for Accounts, Notifications.
struct ConfigSubset * sub
Inherited config items.
Tuple for the results of simple_dialog_new()
struct MuttWindow * sbar
Simple Bar.
struct MuttWindow * dlg
Main Dialog Window.
#define buf_mktemp_draft(buf)
enum UrlScheme url_check_scheme(const char *str)
Check the protocol of a URL.
@ U_MAILTO
Url is mailto://.