diff options
Diffstat (limited to 'sway/commands.c')
-rw-r--r-- | sway/commands.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sway/commands.c b/sway/commands.c index 31d241a8..9b6d6459 100644 --- a/sway/commands.c +++ b/sway/commands.c | |||
@@ -302,7 +302,7 @@ struct cmd_results *execute_command(char *_exec, struct sway_seat *seat) { | |||
302 | head = exec; | 302 | head = exec; |
303 | do { | 303 | do { |
304 | // Extract criteria (valid for this command list only). | 304 | // Extract criteria (valid for this command list only). |
305 | bool has_criteria = false; | 305 | config->handler_context.using_criteria = false; |
306 | if (*head == '[') { | 306 | if (*head == '[') { |
307 | char *error = NULL; | 307 | char *error = NULL; |
308 | struct criteria *criteria = criteria_parse(head, &error); | 308 | struct criteria *criteria = criteria_parse(head, &error); |
@@ -315,7 +315,7 @@ struct cmd_results *execute_command(char *_exec, struct sway_seat *seat) { | |||
315 | views = criteria_get_views(criteria); | 315 | views = criteria_get_views(criteria); |
316 | head += strlen(criteria->raw); | 316 | head += strlen(criteria->raw); |
317 | criteria_destroy(criteria); | 317 | criteria_destroy(criteria); |
318 | has_criteria = true; | 318 | config->handler_context.using_criteria = true; |
319 | // Skip leading whitespace | 319 | // Skip leading whitespace |
320 | head += strspn(head, whitespace); | 320 | head += strspn(head, whitespace); |
321 | } | 321 | } |
@@ -352,7 +352,7 @@ struct cmd_results *execute_command(char *_exec, struct sway_seat *seat) { | |||
352 | goto cleanup; | 352 | goto cleanup; |
353 | } | 353 | } |
354 | 354 | ||
355 | if (!has_criteria) { | 355 | if (!config->handler_context.using_criteria) { |
356 | // without criteria, the command acts upon the focused | 356 | // without criteria, the command acts upon the focused |
357 | // container | 357 | // container |
358 | config->handler_context.current_container = | 358 | config->handler_context.current_container = |