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

@ -25,6 +25,16 @@ void view_destroy(struct roots_view *view) {
free(view);
}
void view_get_size(struct roots_view *view, struct wlr_box *box) {
if (view->get_size) {
view->get_size(view, box);
return;
}
box->x = box->y = 0;
box->width = view->wlr_surface->current.width;
box->height = view->wlr_surface->current.height;
}
void view_get_input_bounds(struct roots_view *view, struct wlr_box *box) {
if (view->get_input_bounds) {
view->get_input_bounds(view, box);