]> git.lizzy.rs Git - bspwm.git/blobdiff - types.c
New message: 'list_rules'
[bspwm.git] / types.c
diff --git a/types.c b/types.c
index d3576bd5c3a9995224d3f04d6553b73ac5fa7181..1454710f95625bc284d93b22226c8a598d9764e5 100644 (file)
--- a/types.c
+++ b/types.c
@@ -27,6 +27,7 @@ monitor_t *make_monitor(xcb_rectangle_t *rect)
         m->rectangle = *rect;
     else
         warn("no rectangle was given for monitor '%s'\n", m->name);
+    m->top_padding = m->right_padding = m->bottom_padding = m->left_padding = 0;
     return m;
 }
 
@@ -47,6 +48,7 @@ client_t *make_client(xcb_window_t win)
 {
     client_t *c = malloc(sizeof(client_t));
     strncpy(c->class_name, MISSING_VALUE, sizeof(c->class_name));
+    c->uid = ++client_uid;
     c->border_width = border_width;
     c->window = win;
     c->floating = c->transient = c->fullscreen = c->locked = c->urgent = false;
@@ -56,7 +58,10 @@ client_t *make_client(xcb_window_t win)
 rule_t *make_rule(void)
 {
     rule_t *r = malloc(sizeof(rule_t));
+    r->uid = ++rule_uid;
     r->effect.floating = false;
+    r->effect.monitor = NULL;
+    r->effect.desktop = NULL;
     r->next = NULL;
     return r;
 }