NeoMutt  2025-12-11-694-ga89709
Teaching an old dog new tricks
DOXYGEN
Loading...
Searching...
No Matches
module.c
Go to the documentation of this file.
1
22
28
29#include "config.h"
30#include <stdbool.h>
31#include <stddef.h>
32#include "mutt/lib.h"
33#include "config/lib.h"
34#include "core/lib.h"
35#include "module_data.h"
36
37extern struct ConfigDef SidebarVars[];
38
39extern const struct Command SbCommands[];
40
44static bool sidebar_init(struct NeoMutt *n)
45{
46 // struct SidebarModuleData *md = MUTT_MEM_CALLOC(1, struct SidebarModuleData);
47 // neomutt_set_module_data(n, MODULE_ID_SIDEBAR, md);
48
49 return true;
50}
51
55static bool sidebar_config_define_variables(struct NeoMutt *n, struct ConfigSet *cs)
56{
58}
59
63static bool sidebar_commands_register(struct NeoMutt *n, struct CommandArray *ca)
64{
65 return commands_register(ca, SbCommands);
66}
67
71static bool sidebar_cleanup(struct NeoMutt *n)
72{
73 // struct SidebarModuleData *md = neomutt_get_module_data(n, MODULE_ID_SIDEBAR);
74 // ASSERT(md);
75
76 // FREE(&md);
77 return true;
78}
79
83const struct Module ModuleSidebar = {
85 "sidebar",
87 NULL, // config_define_types
90 NULL, // gui_init
91 NULL, // gui_cleanup
93};
Convenience wrapper for the config headers.
bool cs_register_variables(const struct ConfigSet *cs, struct ConfigDef vars[])
Register a set of config items.
Definition set.c:290
bool commands_register(struct CommandArray *ca, const struct Command *cmds)
Add commands to Commands array.
Definition command.c:51
Convenience wrapper for the core headers.
const struct Module ModuleSidebar
Module for the Sidebar library.
Definition module.c:83
@ MODULE_ID_SIDEBAR
ModuleSidebar, Sidebar
Definition module_api.h:91
Convenience wrapper for the library headers.
struct ConfigDef SidebarVars[]
Config definitions for the sidebar.
Definition config.c:94
const struct Command SbCommands[]
Sidebar Commands.
Definition sidebar.c:49
static bool sidebar_config_define_variables(struct NeoMutt *n, struct ConfigSet *cs)
Define the Config Variables - Implements Module::config_define_variables()
Definition module.c:55
static bool sidebar_cleanup(struct NeoMutt *n)
Clean up a Module - Implements Module::cleanup()
Definition module.c:71
static bool sidebar_commands_register(struct NeoMutt *n, struct CommandArray *ca)
Register NeoMutt Commands - Implements Module::commands_register()
Definition module.c:63
static bool sidebar_init(struct NeoMutt *n)
Initialise a Module - Implements Module::init()
Definition module.c:44
Sidebar private Module data.
Container for lots of config items.
Definition set.h:251
Container for Accounts, Notifications.
Definition neomutt.h:41