From 211b517e8c62d64e7500194af5b9a0b0e331f27c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kristian=20H=C3=B8gsberg?= Date: Sat, 11 Jan 2014 13:10:21 -0800 Subject: [PATCH] shell: Move maximize and fullscreen bindings to mod + SHIFT mod + f and mod + m conflict with too many application bindings, in particular if mod is mapped to ALT. --- clients/window.c | 1 + desktop-shell/shell.c | 8 ++++---- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/clients/window.c b/clients/window.c index d59b9c7f..dddfc670 100644 --- a/clients/window.c +++ b/clients/window.c @@ -2934,6 +2934,7 @@ keyboard_handle_key(void *data, struct wl_keyboard *keyboard, if (num_syms == 1) sym = syms[0]; + if (sym == XKB_KEY_F5 && input->modifiers == MOD_ALT_MASK) { if (state == WL_KEYBOARD_KEY_STATE_PRESSED) window_set_maximized(window, diff --git a/desktop-shell/shell.c b/desktop-shell/shell.c index a8c4b3ea..ad0a055e 100644 --- a/desktop-shell/shell.c +++ b/desktop-shell/shell.c @@ -5477,10 +5477,10 @@ shell_add_bindings(struct weston_compositor *ec, struct desktop_shell *shell) zoom_key_binding, NULL); weston_compositor_add_key_binding(ec, KEY_PAGEDOWN, mod, zoom_key_binding, NULL); - weston_compositor_add_key_binding(ec, KEY_M, mod, maximize_binding, - NULL); - weston_compositor_add_key_binding(ec, KEY_F, mod, fullscreen_binding, - NULL); + weston_compositor_add_key_binding(ec, KEY_M, mod | MODIFIER_SHIFT, + maximize_binding, NULL); + weston_compositor_add_key_binding(ec, KEY_F, mod | MODIFIER_SHIFT, + fullscreen_binding, NULL); weston_compositor_add_button_binding(ec, BTN_LEFT, mod, move_binding, shell); weston_compositor_add_touch_binding(ec, mod, touch_move_binding, shell);