aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZandr Martin <zandrmartin+git@gmail.com>2016-06-10 07:12:25 -0500
committerZandr Martin <zandrmartin+git@gmail.com>2016-06-10 07:12:25 -0500
commitb00feb25ea324158ba98ba18a0d694e5318682ba (patch)
tree022d42e3249ac77ef2791cbc646f8d7c4b81bcc7
parentb63b01156acda632498c16cf36b176d2ec362a3d (diff)
trigger bg change on config reload
-rw-r--r--sway/commands.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/sway/commands.c b/sway/commands.c
index eab4a1c1..07e7e53d 100644
--- a/sway/commands.c
+++ b/sway/commands.c
@@ -1692,9 +1692,13 @@ static struct cmd_results *cmd_output(int argc, char **argv) {
swayc_t *cont = NULL;
for (int i = 0; i < root_container.children->length; ++i) {
cont = root_container.children->items[i];
- if (cont->name && strcmp(cont->name, output->name) == 0) {
+ if (cont->name && ((strcmp(cont->name, output->name) == 0) || (strcmp(output->name, "*") == 0))) {
apply_output_config(output, cont);
- break;
+
+ if (strcmp(output->name, "*") != 0) {
+ // stop looking if the output config isn't applicable to all outputs
+ break;
+ }
}
}
}