diff options
Diffstat (limited to 'sway/commands/urgent.c')
-rw-r--r-- | sway/commands/urgent.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/sway/commands/urgent.c b/sway/commands/urgent.c index bccb33fe..53c37d4d 100644 --- a/sway/commands/urgent.c +++ b/sway/commands/urgent.c @@ -11,13 +11,12 @@ struct cmd_results *cmd_urgent(int argc, char **argv) { if ((error = checkarg(argc, "urgent", EXPECTED_EQUAL_TO, 1))) { return error; } - struct sway_container *container = - config->handler_context.current_container; - if (container->type != C_VIEW) { + struct sway_container *container = config->handler_context.container; + if (!container->view) { return cmd_results_new(CMD_INVALID, "urgent", "Only views can be urgent"); } - struct sway_view *view = container->sway_view; + struct sway_view *view = container->view; if (strcmp(argv[0], "allow") == 0) { view->allow_request_urgent = true; |