From 9c05c1815625b10ec397c12730b3ce4ad4986d84 Mon Sep 17 00:00:00 2001 From: Michael Stapelberg Date: Wed, 11 May 2011 20:39:18 +0200 Subject: [PATCH] ipc: change border_style to human-readable string instead of enum value --- src/ipc.c | 12 +++++++++++- testcases/t/16-nestedcons.t | 2 +- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/src/ipc.c b/src/ipc.c index d0dc1920..0535d122 100644 --- a/src/ipc.c +++ b/src/ipc.c @@ -206,7 +206,17 @@ void dump_node(yajl_gen gen, struct Con *con, bool inplace_restart) { y(integer, con->layout); ystr("border"); - y(integer, con->border_style); + switch (con->border_style) { + case BS_NORMAL: + ystr("normal"); + break; + case BS_NONE: + ystr("none"); + break; + case BS_1PIXEL: + ystr("1pixel"); + break; + } dump_rect(gen, "rect", con->rect); dump_rect(gen, "window_rect", con->window_rect); diff --git a/testcases/t/16-nestedcons.t b/testcases/t/16-nestedcons.t index e8a124f9..954732dd 100644 --- a/testcases/t/16-nestedcons.t +++ b/testcases/t/16-nestedcons.t @@ -30,7 +30,7 @@ my $expected = { focus => ignore(), focused => 0, urgent => 0, - border => 0, + border => 'normal', 'floating_nodes' => ignore(), };