diff --git a/src/core/display-private.h b/src/core/display-private.h index 95d79e8f7..4ed88e496 100644 --- a/src/core/display-private.h +++ b/src/core/display-private.h @@ -400,10 +400,6 @@ gboolean meta_grab_op_is_mouse (MetaGrabOp op); gboolean meta_grab_op_is_keyboard (MetaGrabOp op); gboolean meta_grab_op_should_block_wayland (MetaGrabOp op); -void meta_display_devirtualize_modifiers (MetaDisplay *display, - MetaVirtualModifier modifiers, - unsigned int *mask); - void meta_display_increment_focus_sentinel (MetaDisplay *display); void meta_display_decrement_focus_sentinel (MetaDisplay *display); gboolean meta_display_focus_sentinel_clear (MetaDisplay *display); diff --git a/src/core/display.c b/src/core/display.c index e99a6d6ad..acb5c0364 100644 --- a/src/core/display.c +++ b/src/core/display.c @@ -2853,35 +2853,6 @@ meta_display_sort_windows_by_stacking (MetaDisplay *display, return copy; } -void -meta_display_devirtualize_modifiers (MetaDisplay *display, - MetaVirtualModifier modifiers, - unsigned int *mask) -{ - *mask = 0; - - if (modifiers & META_VIRTUAL_SHIFT_MASK) - *mask |= ShiftMask; - if (modifiers & META_VIRTUAL_CONTROL_MASK) - *mask |= ControlMask; - if (modifiers & META_VIRTUAL_ALT_MASK) - *mask |= Mod1Mask; - if (modifiers & META_VIRTUAL_META_MASK) - *mask |= display->meta_mask; - if (modifiers & META_VIRTUAL_HYPER_MASK) - *mask |= display->hyper_mask; - if (modifiers & META_VIRTUAL_SUPER_MASK) - *mask |= display->super_mask; - if (modifiers & META_VIRTUAL_MOD2_MASK) - *mask |= Mod2Mask; - if (modifiers & META_VIRTUAL_MOD3_MASK) - *mask |= Mod3Mask; - if (modifiers & META_VIRTUAL_MOD4_MASK) - *mask |= Mod4Mask; - if (modifiers & META_VIRTUAL_MOD5_MASK) - *mask |= Mod5Mask; -} - static void update_window_grab_modifiers (MetaDisplay *display) { diff --git a/src/core/keybindings-private.h b/src/core/keybindings-private.h index 1e6816f71..3d285e5c3 100644 --- a/src/core/keybindings-private.h +++ b/src/core/keybindings-private.h @@ -117,4 +117,8 @@ GList *meta_prefs_get_keybindings (void); void meta_prefs_get_overlay_binding (MetaKeyCombo *combo); const char *meta_prefs_get_iso_next_group_option (void); +void meta_display_devirtualize_modifiers (MetaDisplay *display, + MetaVirtualModifier modifiers, + unsigned int *mask); + #endif diff --git a/src/core/keybindings.c b/src/core/keybindings.c index ebedf218c..acbf5ac93 100644 --- a/src/core/keybindings.c +++ b/src/core/keybindings.c @@ -527,6 +527,35 @@ reload_keycodes (MetaDisplay *display) g_hash_table_foreach (display->key_bindings, binding_reload_keycode_foreach, display); } +void +meta_display_devirtualize_modifiers (MetaDisplay *display, + MetaVirtualModifier modifiers, + unsigned int *mask) +{ + *mask = 0; + + if (modifiers & META_VIRTUAL_SHIFT_MASK) + *mask |= ShiftMask; + if (modifiers & META_VIRTUAL_CONTROL_MASK) + *mask |= ControlMask; + if (modifiers & META_VIRTUAL_ALT_MASK) + *mask |= Mod1Mask; + if (modifiers & META_VIRTUAL_META_MASK) + *mask |= display->meta_mask; + if (modifiers & META_VIRTUAL_HYPER_MASK) + *mask |= display->hyper_mask; + if (modifiers & META_VIRTUAL_SUPER_MASK) + *mask |= display->super_mask; + if (modifiers & META_VIRTUAL_MOD2_MASK) + *mask |= Mod2Mask; + if (modifiers & META_VIRTUAL_MOD3_MASK) + *mask |= Mod3Mask; + if (modifiers & META_VIRTUAL_MOD4_MASK) + *mask |= Mod4Mask; + if (modifiers & META_VIRTUAL_MOD5_MASK) + *mask |= Mod5Mask; +} + static void binding_reload_modifiers_foreach (gpointer key, gpointer value,