From be9348d25c9556bdabb83d964a8761f920fc4a11 Mon Sep 17 00:00:00 2001 From: Ryan Dwyer Date: Sat, 17 Nov 2018 18:32:03 +1000 Subject: Move view {x,y,width,height} into container struct This renames/moves the following properties: * sway_view.{x,y,width,height} -> sway_container.content_{x,y,width,height} * This is required to support placeholder containers as they don't have a view. * sway_container_state.view_{x,y,width,height} -> sway_container_state.content_{x,y,width,height} * To remain consistent with the above. * sway_container_state.con_{x,y,width,height} -> sway_container_state.{x,y,width,height} * The con prefix was there to give it contrast from the view properties, and is no longer useful. The function container_set_geometry_from_floating_view has also been renamed to container_set_geometry_from_content. --- sway/desktop/desktop.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'sway/desktop/desktop.c') diff --git a/sway/desktop/desktop.c b/sway/desktop/desktop.c index 771b58fe..d8dd0240 100644 --- a/sway/desktop/desktop.c +++ b/sway/desktop/desktop.c @@ -28,8 +28,8 @@ void desktop_damage_box(struct wlr_box *box) { void desktop_damage_view(struct sway_view *view) { desktop_damage_whole_container(view->container); struct wlr_box box = { - .x = view->container->current.view_x - view->geometry.x, - .y = view->container->current.view_y - view->geometry.y, + .x = view->container->current.content_x - view->geometry.x, + .y = view->container->current.content_y - view->geometry.y, .width = view->surface->current.width, .height = view->surface->current.height, }; -- cgit v1.2.3