aboutsummaryrefslogtreecommitdiff
path: root/sway/commands
diff options
context:
space:
mode:
Diffstat (limited to 'sway/commands')
-rw-r--r--sway/commands/focus.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/sway/commands/focus.c b/sway/commands/focus.c
index 135a2908..fe15b4c7 100644
--- a/sway/commands/focus.c
+++ b/sway/commands/focus.c
@@ -52,6 +52,10 @@ static struct cmd_results *focus_mode(struct sway_container *con,
}
if (new_focus) {
seat_set_focus(seat, new_focus);
+ } else {
+ return cmd_results_new(CMD_FAILURE, "focus",
+ "Failed to find a %s container in workspace",
+ floating ? "floating" : "tiling");
}
return cmd_results_new(CMD_SUCCESS, NULL, NULL);
}