NeoMutt  2022-04-29-249-gaae397
Teaching an old dog new tricks
DOXYGEN
Mixmaster Function API

Prototype for a Mixmaster Function. More...

+ Collaboration diagram for Mixmaster Function API:

Functions

static int op_exit (struct MixmasterPrivateData *priv, int op)
 exit this menu - Implements mixmaster_function_t - More...
 
static int op_mix_append (struct MixmasterPrivateData *priv, int op)
 append a remailer to the chain - Implements mixmaster_function_t - More...
 
static int op_mix_chain_next (struct MixmasterPrivateData *priv, int op)
 select the next element of the chain - Implements mixmaster_function_t - More...
 
static int op_mix_chain_prev (struct MixmasterPrivateData *priv, int op)
 select the previous element of the chain - Implements mixmaster_function_t - More...
 
static int op_mix_delete (struct MixmasterPrivateData *priv, int op)
 delete a remailer from the chain - Implements mixmaster_function_t - More...
 
static int op_mix_insert (struct MixmasterPrivateData *priv, int op)
 insert a remailer into the chain - Implements mixmaster_function_t - More...
 
static int op_mix_use (struct MixmasterPrivateData *priv, int op)
 accept the chain constructed - Implements mixmaster_function_t - More...
 

Detailed Description

Prototype for a Mixmaster Function.

Parameters
privMixmaster private data
opOperation to perform, e.g. OP_MIXMASTER_NEXT
Return values
enumFunctionRetval

Function Documentation

◆ op_exit()

static int op_exit ( struct MixmasterPrivateData priv,
int  op 
)
static

exit this menu - Implements mixmaster_function_t -

Definition at line 43 of file functions.c.

44{
45 return FR_NO_ACTION;
46}
@ FR_NO_ACTION
Valid function - no action performed.
Definition: dispatcher.h:37

◆ op_mix_append()

static int op_mix_append ( struct MixmasterPrivateData priv,
int  op 
)
static

append a remailer to the chain - Implements mixmaster_function_t -

Definition at line 51 of file functions.c.

52{
54 return FR_ERROR;
55
56 return FR_SUCCESS;
57}
@ FR_SUCCESS
Valid function - successfully performed.
Definition: dispatcher.h:39
@ FR_ERROR
Valid function - error occurred.
Definition: dispatcher.h:38
struct MuttWindow * win_chain
Chain Window.
Definition: private_data.h:32
struct MuttWindow * win_hosts
Hosts Window.
Definition: private_data.h:31
bool win_chain_append(struct MuttWindow *win, struct Remailer *r)
Add an item to the Chain, after the current item.
Definition: win_chain.c:335
struct Remailer * win_hosts_get_selection(struct MuttWindow *win)
Get the current selection.
Definition: win_hosts.c:228
+ Here is the call graph for this function:

◆ op_mix_chain_next()

static int op_mix_chain_next ( struct MixmasterPrivateData priv,
int  op 
)
static

select the next element of the chain - Implements mixmaster_function_t -

Definition at line 62 of file functions.c.

63{
64 if (win_chain_next(priv->win_chain))
65 return FR_SUCCESS;
66
67 return FR_ERROR;
68}
bool win_chain_next(struct MuttWindow *win)
Select the next entry in the Chain list.
Definition: win_chain.c:282
+ Here is the call graph for this function:

◆ op_mix_chain_prev()

static int op_mix_chain_prev ( struct MixmasterPrivateData priv,
int  op 
)
static

select the previous element of the chain - Implements mixmaster_function_t -

Definition at line 73 of file functions.c.

74{
75 if (win_chain_prev(priv->win_chain))
76 return FR_SUCCESS;
77
78 return FR_ERROR;
79}
bool win_chain_prev(struct MuttWindow *win)
Select the previous entry in the Chain list.
Definition: win_chain.c:308
+ Here is the call graph for this function:

◆ op_mix_delete()

static int op_mix_delete ( struct MixmasterPrivateData priv,
int  op 
)
static

delete a remailer from the chain - Implements mixmaster_function_t -

Definition at line 84 of file functions.c.

85{
86 if (!win_chain_delete(priv->win_chain))
87 return FR_ERROR;
88
89 return FR_SUCCESS;
90}
bool win_chain_delete(struct MuttWindow *win)
Delete the current item from the Chain.
Definition: win_chain.c:385
+ Here is the call graph for this function:

◆ op_mix_insert()

static int op_mix_insert ( struct MixmasterPrivateData priv,
int  op 
)
static

insert a remailer into the chain - Implements mixmaster_function_t -

Definition at line 95 of file functions.c.

96{
98 return FR_ERROR;
99
100 return FR_SUCCESS;
101}
bool win_chain_insert(struct MuttWindow *win, struct Remailer *r)
Add an item to the Chain, before the current item.
Definition: win_chain.c:354
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ op_mix_use()

static int op_mix_use ( struct MixmasterPrivateData priv,
int  op 
)
static

accept the chain constructed - Implements mixmaster_function_t -

Definition at line 106 of file functions.c.

107{
108 // If we don't have a chain yet, insert the current item
109 if (win_chain_get_length(priv->win_chain) == 0)
110 op_mix_insert(priv, op);
111
112 if (win_chain_validate(priv->win_chain))
113 return FR_DONE;
114
115 return FR_SUCCESS;
116}
@ FR_DONE
Exit the Dialog.
Definition: dispatcher.h:35
static int op_mix_insert(struct MixmasterPrivateData *priv, int op)
insert a remailer into the chain - Implements mixmaster_function_t -
Definition: functions.c:95
bool win_chain_validate(struct MuttWindow *win)
Validate the Chain.
Definition: win_chain.c:417
int win_chain_get_length(struct MuttWindow *win)
Get the number of Remailers in the Chain.
Definition: win_chain.c:267
+ Here is the call graph for this function: