From 70f5d6fcf3219f122077b7e8d0b43a464f4e3fd4 Mon Sep 17 00:00:00 2001
From: Ryan Dwyer <ryandwyer1@gmail.com>
Date: Sat, 26 May 2018 16:32:24 +1000
Subject: [PATCH] Rename container_set_geometry_from_view

---
 include/sway/tree/container.h |  2 +-
 sway/tree/container.c         | 16 ++++++++--------
 sway/tree/view.c              |  4 ++--
 3 files changed, 11 insertions(+), 11 deletions(-)

diff --git a/include/sway/tree/container.h b/include/sway/tree/container.h
index 4b686040..38c0f35d 100644
--- a/include/sway/tree/container.h
+++ b/include/sway/tree/container.h
@@ -238,7 +238,7 @@ size_t container_titlebar_height(void);
 
 void container_set_floating(struct sway_container *container, bool enable);
 
-void container_set_geometry_from_view(struct sway_container *container);
+void container_set_geometry_from_floating_view(struct sway_container *con);
 
 /**
  * Determine if the given container is itself floating.
diff --git a/sway/tree/container.c b/sway/tree/container.c
index 7928ffc3..7430aebb 100644
--- a/sway/tree/container.c
+++ b/sway/tree/container.c
@@ -930,23 +930,23 @@ void container_set_floating(struct sway_container *container, bool enable) {
 	container_damage_whole(container);
 }
 
-void container_set_geometry_from_view(struct sway_container *container) {
-	if (!sway_assert(container->type == C_VIEW, "Expected a view")) {
+void container_set_geometry_from_floating_view(struct sway_container *con) {
+	if (!sway_assert(con->type == C_VIEW, "Expected a view")) {
 		return;
 	}
-	if (!sway_assert(container_is_floating(container),
+	if (!sway_assert(container_is_floating(con),
 				"Expected a floating view")) {
 		return;
 	}
-	struct sway_view *view = container->sway_view;
+	struct sway_view *view = con->sway_view;
 	size_t border_width = view->border_thickness * (view->border != B_NONE);
 	size_t top =
 		view->border == B_NORMAL ? container_titlebar_height() : border_width;
 
-	container->x = view->x - border_width;
-	container->y = view->y - top;
-	container->width = view->width + border_width * 2;
-	container->height = top + view->height + border_width;
+	con->x = view->x - border_width;
+	con->y = view->y - top;
+	con->width = view->width + border_width * 2;
+	con->height = top + view->height + border_width;
 }
 
 bool container_self_or_parent_floating(struct sway_container *container) {
diff --git a/sway/tree/view.c b/sway/tree/view.c
index 065d00db..30d5c7b4 100644
--- a/sway/tree/view.c
+++ b/sway/tree/view.c
@@ -567,7 +567,7 @@ void view_update_position(struct sway_view *view, double lx, double ly) {
 	container_damage_whole(view->swayc);
 	view->x = lx;
 	view->y = ly;
-	container_set_geometry_from_view(view->swayc);
+	container_set_geometry_from_floating_view(view->swayc);
 	container_damage_whole(view->swayc);
 }
 
@@ -579,7 +579,7 @@ void view_update_size(struct sway_view *view, int width, int height) {
 	view->width = width;
 	view->height = height;
 	if (container_is_floating(view->swayc)) {
-		container_set_geometry_from_view(view->swayc);
+		container_set_geometry_from_floating_view(view->swayc);
 	}
 	container_damage_whole(view->swayc);
 }