Completely fix resize offset

This commit is contained in:
emersion 2017-09-30 14:02:09 +02:00
parent 77d28183b5
commit 74f2d0cd63
No known key found for this signature in database
GPG key ID: 0FDE7BE0E88F5E48
4 changed files with 19 additions and 5 deletions

View file

@ -37,8 +37,10 @@ void view_begin_resize(struct roots_input *input, struct wlr_cursor *cursor,
input->offs_y = cursor->y;
input->view_x = view->x;
input->view_y = view->y;
input->view_width = view->wlr_surface->current.width;
input->view_height = view->wlr_surface->current.height;
struct wlr_box size;
view_get_size(view, &size);
input->view_width = size.width;
input->view_height = size.height;
input->resize_edges = edges;
wlr_seat_pointer_clear_focus(input->wl_seat);
}