mirror of
https://codeberg.org/dwl/dwl.git
synced 2026-11-11 15:43:13 +00:00
remove LISTEN_STATIC
It's only used in createidleinhibitor().
This commit is contained in:
@@ -83,7 +83,6 @@
|
||||
#define VISIBLEON(C, M) ((M) && (C)->mon == (M) && ((C)->tags & (M)->tagset[(M)->seltags]))
|
||||
#define TAGMASK ((1u << TAGCOUNT) - 1)
|
||||
#define LISTEN(E, L, H) wl_signal_add((E), ((L)->notify = (H), (L)))
|
||||
#define LISTEN_STATIC(E, H) do { struct wl_listener *_l = ecalloc(1, sizeof(*_l)); _l->notify = (H); wl_signal_add((E), _l); } while (0)
|
||||
|
||||
/* enums */
|
||||
enum { CurNormal, CurPressed, CurMove, CurResize }; /* cursor */
|
||||
@@ -1103,7 +1102,8 @@ void
|
||||
createidleinhibitor(struct wl_listener *listener, void *data)
|
||||
{
|
||||
struct wlr_idle_inhibitor_v1 *idle_inhibitor = data;
|
||||
LISTEN_STATIC(&idle_inhibitor->events.destroy, destroyidleinhibitor);
|
||||
struct wl_listener *destroy = ecalloc(1, sizeof(*destroy));
|
||||
LISTEN(&idle_inhibitor->events.destroy, destroy, destroyidleinhibitor);
|
||||
|
||||
checkidleinhibitor(NULL);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user