aboutsummaryrefslogtreecommitdiffstats
path: root/sway/commands/fullscreen.c
diff options
context:
space:
mode:
authorLibravatar M Stoeckl <code@mstoeckl.com>2019-01-10 18:27:21 -0500
committerLibravatar M Stoeckl <code@mstoeckl.com>2019-01-14 08:05:29 -0500
commit2a684cad5fc8e12a8e47a7fd00e2b7c66b43afb0 (patch)
tree56332b9c150459beb5aef94605372ef179ec8854 /sway/commands/fullscreen.c
parentRemove 'input' field of IPC command return json (diff)
downloadsway-2a684cad5fc8e12a8e47a7fd00e2b7c66b43afb0.tar.gz
sway-2a684cad5fc8e12a8e47a7fd00e2b7c66b43afb0.tar.zst
sway-2a684cad5fc8e12a8e47a7fd00e2b7c66b43afb0.zip
Remove now-unused "input" argument of cmd_results_new
Patch tested by compiling with `__attribute__ ((format (printf, 2, 3)))` applied to `cmd_results_new`. String usage constants have been converted from pointers to arrays when encountered. General handler format strings were sometimes modified to include the old input string, especially for unknown command errors.
Diffstat (limited to 'sway/commands/fullscreen.c')
-rw-r--r--sway/commands/fullscreen.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/sway/commands/fullscreen.c b/sway/commands/fullscreen.c
index b78187d9..920b9bd0 100644
--- a/sway/commands/fullscreen.c
+++ b/sway/commands/fullscreen.c
@@ -13,14 +13,14 @@ struct cmd_results *cmd_fullscreen(int argc, char **argv) {
13 return error; 13 return error;
14 } 14 }
15 if (!root->outputs->length) { 15 if (!root->outputs->length) {
16 return cmd_results_new(CMD_FAILURE, "fullscreen", 16 return cmd_results_new(CMD_FAILURE,
17 "Can't run this command while there's no outputs connected."); 17 "Can't run this command while there's no outputs connected.");
18 } 18 }
19 struct sway_node *node = config->handler_context.node; 19 struct sway_node *node = config->handler_context.node;
20 struct sway_container *container = config->handler_context.container; 20 struct sway_container *container = config->handler_context.container;
21 struct sway_workspace *workspace = config->handler_context.workspace; 21 struct sway_workspace *workspace = config->handler_context.workspace;
22 if (node->type == N_WORKSPACE && workspace->tiling->length == 0) { 22 if (node->type == N_WORKSPACE && workspace->tiling->length == 0) {
23 return cmd_results_new(CMD_FAILURE, "fullscreen", 23 return cmd_results_new(CMD_FAILURE,
24 "Can't fullscreen an empty workspace"); 24 "Can't fullscreen an empty workspace");
25 } 25 }
26 if (node->type == N_WORKSPACE) { 26 if (node->type == N_WORKSPACE) {
@@ -38,5 +38,5 @@ struct cmd_results *cmd_fullscreen(int argc, char **argv) {
38 container_set_fullscreen(container, enable); 38 container_set_fullscreen(container, enable);
39 arrange_workspace(workspace); 39 arrange_workspace(workspace);
40 40
41 return cmd_results_new(CMD_SUCCESS, NULL, NULL); 41 return cmd_results_new(CMD_SUCCESS, NULL);
42} 42}