summaryrefslogtreecommitdiffstats
path: root/alerts.c
diff options
context:
space:
mode:
authornicm <nicm>2016-10-16 22:18:04 +0000
committernicm <nicm>2016-10-16 22:18:04 +0000
commitfe106842c879c8f2d0419afba4f90ce0c62c5e80 (patch)
tree6c36f504ab56639f6194d64b303c45d8d4e88153 /alerts.c
parent41e633acf5d08cbd8976771bd2b74f14abda3969 (diff)
Use notifys for alerts too.
Diffstat (limited to 'alerts.c')
-rw-r--r--alerts.c11
1 files changed, 3 insertions, 8 deletions
diff --git a/alerts.c b/alerts.c
index bcca8f3d..ef869ae8 100644
--- a/alerts.c
+++ b/alerts.c
@@ -75,17 +75,12 @@ alerts_callback(__unused int fd, __unused short events, __unused void *arg)
static void
alerts_run_hook(struct session *s, struct winlink *wl, int flags)
{
- struct cmd_find_state fs;
-
- if (cmd_find_from_winlink(&fs, s, wl) != 0)
- return;
-
if (flags & WINDOW_BELL)
- hooks_run(s->hooks, NULL, &fs, "alert-bell");
+ notify_winlink("alert-bell", s, wl);
if (flags & WINDOW_SILENCE)
- hooks_run(s->hooks, NULL, &fs, "alert-silence");
+ notify_winlink("alert-silence", s, wl);
if (flags & WINDOW_ACTIVITY)
- hooks_run(s->hooks, NULL, &fs, "alert-activity");
+ notify_winlink("alert-activity", s, wl);
}
static int