summaryrefslogtreecommitdiff
path: root/sway/commands/focus.c
diff options
context:
space:
mode:
authorTony Crisci <[email protected]>2018-02-24 13:22:57 -0500
committerTony Crisci <[email protected]>2018-02-24 13:22:57 -0500
commit7262bf655f7a19af1d4c8681be74d70bfc6b8911 (patch)
tree2f949def2ad25fff6e642fcbd30d8c9d2bc8db21 /sway/commands/focus.c
parent5b219a15982b9626f85535c082ee2adb460ad11d (diff)
remove checks for command handlers
Diffstat (limited to 'sway/commands/focus.c')
-rw-r--r--sway/commands/focus.c14
1 files changed, 0 insertions, 14 deletions
diff --git a/sway/commands/focus.c b/sway/commands/focus.c
index ba47d1e1..f1a8078f 100644
--- a/sway/commands/focus.c
+++ b/sway/commands/focus.c
@@ -33,20 +33,6 @@ static bool parse_movement_direction(const char *name, enum movement_direction *
struct cmd_results *cmd_focus(int argc, char **argv) {
swayc_t *con = config->handler_context.current_container;
struct sway_seat *seat = config->handler_context.seat;
-
- if (!sway_assert(seat, "'focus' command called without seat context")) {
- return cmd_results_new(CMD_FAILURE, "focus",
- "Command 'focus' called without seat context (this is a bug in sway)");
- }
-
- if (config->reading) {
- return cmd_results_new(CMD_FAILURE, "focus",
- "Command 'focus' cannot be used in the config file");
- }
- if (con == NULL) {
- wlr_log(L_DEBUG, "no container to focus");
- return cmd_results_new(CMD_SUCCESS, NULL, NULL);
- }
if (con->type < C_WORKSPACE) {
return cmd_results_new(CMD_FAILURE, "focus",
"Command 'focus' cannot be used above the workspace level");