Store geometry in the view and handle any floating view resizing

This commit is contained in:
Ryan Dwyer 2018-08-18 15:10:06 +10:00
parent 4e755c4b12
commit b0a5f3a25f
11 changed files with 144 additions and 112 deletions

View file

@ -522,13 +522,8 @@ static void surface_at_view(struct sway_container *swayc, double lx, double ly,
return;
}
struct sway_view *sview = swayc->sway_view;
double view_sx = lx - sview->x;
double view_sy = ly - sview->y;
struct wlr_box geometry;
view_get_geometry(sview, &geometry);
view_sx += geometry.x;
view_sy += geometry.y;
double view_sx = lx - sview->x + sview->geometry.x;
double view_sy = ly - sview->y + sview->geometry.y;
double _sx, _sy;
struct wlr_surface *_surface = NULL;