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.
dev
Kristian Høgsberg 11 years ago
parent b637a40df9
commit 211b517e8c
  1. 1
      clients/window.c
  2. 8
      desktop-shell/shell.c

@ -2934,6 +2934,7 @@ keyboard_handle_key(void *data, struct wl_keyboard *keyboard,
if (num_syms == 1) if (num_syms == 1)
sym = syms[0]; sym = syms[0];
if (sym == XKB_KEY_F5 && input->modifiers == MOD_ALT_MASK) { if (sym == XKB_KEY_F5 && input->modifiers == MOD_ALT_MASK) {
if (state == WL_KEYBOARD_KEY_STATE_PRESSED) if (state == WL_KEYBOARD_KEY_STATE_PRESSED)
window_set_maximized(window, window_set_maximized(window,

@ -5477,10 +5477,10 @@ shell_add_bindings(struct weston_compositor *ec, struct desktop_shell *shell)
zoom_key_binding, NULL); zoom_key_binding, NULL);
weston_compositor_add_key_binding(ec, KEY_PAGEDOWN, mod, weston_compositor_add_key_binding(ec, KEY_PAGEDOWN, mod,
zoom_key_binding, NULL); zoom_key_binding, NULL);
weston_compositor_add_key_binding(ec, KEY_M, mod, maximize_binding, weston_compositor_add_key_binding(ec, KEY_M, mod | MODIFIER_SHIFT,
NULL); maximize_binding, NULL);
weston_compositor_add_key_binding(ec, KEY_F, mod, fullscreen_binding, weston_compositor_add_key_binding(ec, KEY_F, mod | MODIFIER_SHIFT,
NULL); fullscreen_binding, NULL);
weston_compositor_add_button_binding(ec, BTN_LEFT, mod, move_binding, weston_compositor_add_button_binding(ec, BTN_LEFT, mod, move_binding,
shell); shell);
weston_compositor_add_touch_binding(ec, mod, touch_move_binding, shell); weston_compositor_add_touch_binding(ec, mod, touch_move_binding, shell);

Loading…
Cancel
Save