aboutsummaryrefslogtreecommitdiff
path: root/rootston/keyboard.c
diff options
context:
space:
mode:
authorDrew DeVault <sir@cmpwn.com>2017-11-22 16:12:46 -0500
committerGitHub <noreply@github.com>2017-11-22 16:12:46 -0500
commitaf3dea6d432d084d2c1e7ae55c3144806c591629 (patch)
tree89a6487b1e3778a16252134f0dfad3218b6f9b7e /rootston/keyboard.c
parentb083b1708b208c9f9b5332ee291ffc0f7ef3b44d (diff)
parent903ba1c9b327e245b58c6e8d0277685e2fdcc745 (diff)
Merge pull request #445 from acrisci/feature/maximize-command
rootston: maximize command
Diffstat (limited to 'rootston/keyboard.c')
-rw-r--r--rootston/keyboard.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/rootston/keyboard.c b/rootston/keyboard.c
index f3fc9a85..0b7afcb3 100644
--- a/rootston/keyboard.c
+++ b/rootston/keyboard.c
@@ -106,6 +106,11 @@ static void keyboard_binding_execute(struct roots_keyboard *keyboard,
} else if (pid == 0) {
execl("/bin/sh", "/bin/sh", "-c", shell_cmd, (void *)NULL);
}
+ } else if (strcmp(command, "maximize") == 0) {
+ struct roots_view *focus = roots_seat_get_focus(seat);
+ if (focus != NULL) {
+ view_maximize(focus, !focus->maximized);
+ }
} else {
wlr_log(L_ERROR, "unknown binding command: %s", command);
}