NeoMutt  2024-12-12-14-g7b49f7
Teaching an old dog new tricks
DOXYGEN
Loading...
Searching...
No Matches
notify.c
Go to the documentation of this file.
1
29#include "config.h"
30#include <stddef.h>
31#include "mutt/lib.h"
32#include "notify2.h"
33
34struct Notify;
35
36struct Notify *ColorsNotify = NULL;
37
43{
46}
47
52{
54}
55
61void mutt_color_observer_add(observer_t callback, void *global_data)
62{
63 notify_observer_add(ColorsNotify, NT_COLOR, callback, global_data);
64}
65
71void mutt_color_observer_remove(observer_t callback, void *global_data)
72{
73 notify_observer_remove(ColorsNotify, callback, global_data);
74}
void mutt_color_observer_remove(observer_t callback, void *global_data)
Remove an observer.
Definition: notify.c:71
struct Notify * ColorsNotify
Notifications: ColorId, EventColor.
Definition: notify.c:36
void color_notify_init(struct Notify *parent)
Initialise the Colour notification.
Definition: notify.c:42
void mutt_color_observer_add(observer_t callback, void *global_data)
Add an observer.
Definition: notify.c:61
void color_notify_cleanup(void)
Free the Colour notification.
Definition: notify.c:51
Convenience wrapper for the library headers.
bool notify_observer_remove(struct Notify *notify, const observer_t callback, const void *global_data)
Remove an observer from an object.
Definition: notify.c:230
bool notify_observer_add(struct Notify *notify, enum NotifyType type, observer_t callback, void *global_data)
Add an observer to an object.
Definition: notify.c:191
struct Notify * notify_new(void)
Create a new notifications handler.
Definition: notify.c:62
void notify_set_parent(struct Notify *notify, struct Notify *parent)
Set the parent notification handler.
Definition: notify.c:95
void notify_free(struct Notify **ptr)
Free a notification handler.
Definition: notify.c:75
Colour notifications.
@ NT_COLOR
Colour has changed, NotifyColor, EventColor.
Definition: notify_type.h:41
int(* observer_t)(struct NotifyCallback *nc)
Definition: observer.h:54
Notification API.
Definition: notify.c:53
struct Notify * parent
Parent of the notification object.
Definition: notify.c:54