ipc: send 'percent': null when percent is not relevant for the container
This commit is contained in:
parent
f0aa52f674
commit
36fde6dbe1
|
@ -193,7 +193,9 @@ void dump_node(yajl_gen gen, struct Con *con, bool inplace_restart) {
|
|||
}
|
||||
|
||||
ystr("percent");
|
||||
y(double, con->percent);
|
||||
if (con->percent == 0.0)
|
||||
y(null);
|
||||
else y(double, con->percent);
|
||||
|
||||
ystr("urgent");
|
||||
y(integer, con->urgent);
|
||||
|
|
|
@ -25,7 +25,7 @@ my $expected = {
|
|||
window_rect => ignore(),
|
||||
geometry => ignore(),
|
||||
swallows => ignore(),
|
||||
percent => 0,
|
||||
percent => undef,
|
||||
layout => 'default',
|
||||
focus => ignore(),
|
||||
focused => 0,
|
||||
|
|
Loading…
Reference in New Issue