keybindings: Use current monitor for move-to-center

Move to center uses all monitors for calculating work area.

This can lead to an unexpected behaviour on some monitor
configurations resulting in current window being split between
monitors. We should move window to the center of the active display.

Closes https://gitlab.gnome.org/GNOME/mutter/-/issues/1073
This commit is contained in:
Sergey Zigachev 2020-04-30 18:34:38 +05:00
parent aedf692e0c
commit 5201d77b0b

View File

@ -3112,7 +3112,7 @@ handle_move_to_center (MetaDisplay *display,
MetaRectangle work_area;
MetaRectangle frame_rect;
meta_window_get_work_area_all_monitors (window, &work_area);
meta_window_get_work_area_current_monitor (window, &work_area);
meta_window_get_frame_rect (window, &frame_rect);
meta_window_move_frame (window,