Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 14 additions & 9 deletions src/core/window.c
Original file line number Diff line number Diff line change
Expand Up @@ -7378,16 +7378,19 @@ meta_window_handle_mouse_grab_op_event (MetaWindow *window,
meta_display_check_threshold_reached (window->display, x, y);
if (meta_grab_op_is_moving (window->display->grab_op))
{
update_move (window,
modifier_state & CLUTTER_SHIFT_MASK,
x, y);
if (meta_grab_op_is_mouse (window->display->grab_op))
update_move (window,
modifier_state & CLUTTER_SHIFT_MASK,
x, y);
}
else if (meta_grab_op_is_resizing (window->display->grab_op))
{
update_resize (window,
modifier_state & CLUTTER_SHIFT_MASK || (window->htile_match != NULL || window->vtile_match != NULL),
x, y,
FALSE);
if (meta_grab_op_is_mouse (window->display->grab_op) ||
window->display->grab_op == META_GRAB_OP_KEYBOARD_RESIZING_UNKNOWN)
update_resize (window,
modifier_state & CLUTTER_SHIFT_MASK || (window->htile_match != NULL || window->vtile_match != NULL),
x, y,
FALSE);
}
return TRUE;

Expand Down Expand Up @@ -7758,7 +7761,8 @@ warp_grab_pointer (MetaWindow *window,
*x = CLAMP (*x, 0, display_rect.width - 1);
*y = CLAMP (*y, 0, display_rect.height - 1);

meta_x11_error_trap_push (display->x11_display);
if (display->x11_display)
meta_x11_error_trap_push (display->x11_display);

meta_topic (META_DEBUG_WINDOW_OPS,
"Warping pointer to %d,%d with window at %d,%d\n",
Expand All @@ -7782,7 +7786,8 @@ warp_grab_pointer (MetaWindow *window,
clutter_seat_warp_pointer (seat, *x, *y);
}

if (meta_x11_error_trap_pop_with_return (display->x11_display) != Success)
if (display->x11_display &&
meta_x11_error_trap_pop_with_return (display->x11_display) != Success)
{
meta_verbose ("Failed to warp pointer for window %s\n",
window->desc);
Expand Down
6 changes: 6 additions & 0 deletions src/wayland/meta-window-wayland.c
Original file line number Diff line number Diff line change
Expand Up @@ -1260,6 +1260,12 @@ meta_window_wayland_finish_move_resize (MetaWindow *window,
gravity = META_GRAVITY_STATIC;
meta_window_move_resize_internal (window, flags, gravity, rect);

if (is_window_being_resized &&
meta_grab_op_is_keyboard (window->display->grab_op))
{
meta_window_update_keyboard_resize (window, FALSE);
}

/* Force a NOT_MAXIMIZED -> MAXIMIZED configure transition for clients that
* need it to fire their 'maximize' event. Triggered when the client requested
* maximization before completing its first configure-ack-commit cycle. */
Expand Down