aboutsummaryrefslogtreecommitdiff
path: root/swaybar/event_loop.c
diff options
context:
space:
mode:
authorDrew DeVault <sir@cmpwn.com>2018-04-12 20:19:54 -0400
committerDrew DeVault <sir@cmpwn.com>2018-04-12 20:19:54 -0400
commitcd1b32453a9296c18b28bff71607aeb22987b5cd (patch)
treec653c6d525b471914c01a9d7ae543f521b6138ed /swaybar/event_loop.c
parent8e06985cc1b479724446fba752e0fecfb998e87b (diff)
parent5785170421dc38437acde8bb61068cd16fda716c (diff)
Merge branch 'wlroots'
Diffstat (limited to 'swaybar/event_loop.c')
-rw-r--r--swaybar/event_loop.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/swaybar/event_loop.c b/swaybar/event_loop.c
index 0d1be1da..748372ed 100644
--- a/swaybar/event_loop.c
+++ b/swaybar/event_loop.c
@@ -4,19 +4,18 @@
#include <string.h>
#include <strings.h>
#include <poll.h>
-#include "swaybar/bar.h"
+#include <time.h>
#include "swaybar/event_loop.h"
#include "list.h"
-#include "log.h"
struct event_item {
- void(*cb)(int fd, short mask, void *data);
+ void (*cb)(int fd, short mask, void *data);
void *data;
};
struct timer_item {
timer_t timer;
- void(*cb)(timer_t timer, void *data);
+ void (*cb)(timer_t timer, void *data);
void *data;
};
@@ -138,7 +137,8 @@ void event_loop_poll() {
void init_event_loop() {
event_loop.fds.length = 0;
event_loop.fds.capacity = 10;
- event_loop.fds.items = malloc(event_loop.fds.capacity * sizeof(struct pollfd));
+ event_loop.fds.items = malloc(
+ event_loop.fds.capacity * sizeof(struct pollfd));
event_loop.items = create_list();
event_loop.timers = create_list();
}