libweston: Rename weston_surface::configure to ::committed

Signed-off-by: Quentin Glidic <sardemff7+git@sardemff7.net>
Reviewed-by: Jonas Ã…dahl <jadahl@gmail.com>
Acked-by: Giulio Camuffo <giulio.camuffo@kdab.com>

Differential Revision: https://phabricator.freedesktop.org/D1246
diff --git a/desktop-shell/input-panel.c b/desktop-shell/input-panel.c
index 2e18e28..58a4cd0 100644
--- a/desktop-shell/input-panel.c
+++ b/desktop-shell/input-panel.c
@@ -166,9 +166,9 @@
 }
 
 static void
-input_panel_configure(struct weston_surface *surface, int32_t sx, int32_t sy)
+input_panel_committed(struct weston_surface *surface, int32_t sx, int32_t sy)
 {
-	struct input_panel_surface *ip_surface = surface->configure_private;
+	struct input_panel_surface *ip_surface = surface->committed_private;
 	struct desktop_shell *shell = ip_surface->shell;
 	struct weston_view *view;
 	float x, y;
@@ -201,7 +201,7 @@
 	wl_list_remove(&input_panel_surface->surface_destroy_listener.link);
 	wl_list_remove(&input_panel_surface->link);
 
-	input_panel_surface->surface->configure = NULL;
+	input_panel_surface->surface->committed = NULL;
 	weston_surface_set_label_func(input_panel_surface->surface, NULL);
 	weston_view_destroy(input_panel_surface->view);
 
@@ -211,8 +211,8 @@
 static struct input_panel_surface *
 get_input_panel_surface(struct weston_surface *surface)
 {
-	if (surface->configure == input_panel_configure) {
-		return surface->configure_private;
+	if (surface->committed == input_panel_committed) {
+		return surface->committed_private;
 	} else {
 		return NULL;
 	}
@@ -242,8 +242,8 @@
 	if (!input_panel_surface)
 		return NULL;
 
-	surface->configure = input_panel_configure;
-	surface->configure_private = input_panel_surface;
+	surface->committed = input_panel_committed;
+	surface->committed_private = input_panel_surface;
 	weston_surface_set_label_func(surface, input_panel_get_label);
 
 	input_panel_surface->shell = shell;
@@ -328,7 +328,7 @@
 	if (!ipsurf) {
 		wl_resource_post_error(surface_resource,
 				       WL_DISPLAY_ERROR_INVALID_OBJECT,
-				       "surface->configure already set");
+				       "surface->committed already set");
 		return;
 	}
 
diff --git a/desktop-shell/shell.c b/desktop-shell/shell.c
index 64979cd..b6ee729 100644
--- a/desktop-shell/shell.c
+++ b/desktop-shell/shell.c
@@ -705,15 +705,15 @@
 
 /* no-op func for checking focus surface */
 static void
-focus_surface_configure(struct weston_surface *es, int32_t sx, int32_t sy)
+focus_surface_committed(struct weston_surface *es, int32_t sx, int32_t sy)
 {
 }
 
 static struct focus_surface *
 get_focus_surface(struct weston_surface *surface)
 {
-	if (surface->configure == focus_surface_configure)
-		return surface->configure_private;
+	if (surface->committed == focus_surface_committed)
+		return surface->committed_private;
 	else
 		return NULL;
 }
@@ -721,7 +721,7 @@
 static bool
 is_focus_surface (struct weston_surface *es)
 {
-	return (es->configure == focus_surface_configure);
+	return (es->committed == focus_surface_committed);
 }
 
 static bool
@@ -748,10 +748,10 @@
 		return NULL;
 	}
 
-	surface->configure = focus_surface_configure;
+	surface->committed = focus_surface_committed;
 	surface->output = output;
 	surface->is_mapped = true;
-	surface->configure_private = fsurf;
+	surface->committed_private = fsurf;
 	weston_surface_set_label_func(surface, focus_surface_get_label);
 
 	fsurf->view = weston_view_create(surface);
@@ -2777,7 +2777,7 @@
 static int
 black_surface_get_label(struct weston_surface *surface, char *buf, size_t len)
 {
-	struct weston_view *fs_view = surface->configure_private;
+	struct weston_view *fs_view = surface->committed_private;
 	struct weston_surface *fs_surface = fs_view->surface;
 	int n;
 	int rem;
@@ -2803,7 +2803,7 @@
 }
 
 static void
-black_surface_configure(struct weston_surface *es, int32_t sx, int32_t sy);
+black_surface_committed(struct weston_surface *es, int32_t sx, int32_t sy);
 
 static struct weston_view *
 create_black_surface(struct weston_compositor *ec,
@@ -2825,8 +2825,8 @@
 		return NULL;
 	}
 
-	surface->configure = black_surface_configure;
-	surface->configure_private = fs_view;
+	surface->committed = black_surface_committed;
+	surface->committed_private = fs_view;
 	weston_surface_set_label_func(surface, black_surface_get_label);
 	weston_surface_set_color(surface, 0.0, 0.0, 0.0, 1);
 	pixman_region32_fini(&surface->opaque);
@@ -3591,7 +3591,7 @@
 	 * we can always remove the listener.
 	 */
 	wl_list_remove(&shsurf->surface_destroy_listener.link);
-	shsurf->surface->configure = NULL;
+	shsurf->surface->committed = NULL;
 	weston_surface_set_label_func(shsurf->surface, NULL);
 	free(shsurf->title);
 
@@ -3678,13 +3678,13 @@
 }
 
 static void
-shell_surface_configure(struct weston_surface *, int32_t, int32_t);
+shell_surface_committed(struct weston_surface *, int32_t, int32_t);
 
 struct shell_surface *
 get_shell_surface(struct weston_surface *surface)
 {
-	if (surface->configure == shell_surface_configure)
-		return surface->configure_private;
+	if (surface->committed == shell_surface_committed)
+		return surface->committed_private;
 	else
 		return NULL;
 }
@@ -3696,7 +3696,7 @@
 {
 	struct shell_surface *shsurf;
 
-	assert(surface->configure == NULL);
+	assert(surface->committed == NULL);
 
 	shsurf = calloc(1, sizeof *shsurf);
 	if (!shsurf) {
@@ -3711,8 +3711,8 @@
 		return NULL;
 	}
 
-	surface->configure = shell_surface_configure;
-	surface->configure_private = shsurf;
+	surface->committed = shell_surface_committed;
+	surface->committed_private = shsurf;
 	weston_surface_set_label_func(surface, shell_surface_get_label);
 
 	shsurf->resource_destroy_listener.notify = handle_resource_destroy;
@@ -4366,7 +4366,7 @@
 	wl_list_for_each_safe(v, next, &layer->view_list.link, layer_link.link) {
 		if (v->output == ev->output && v != ev) {
 			weston_view_unmap(v);
-			v->surface->configure = NULL;
+			v->surface->committed = NULL;
 			weston_surface_set_label_func(v->surface, NULL);
 		}
 	}
@@ -4403,9 +4403,9 @@
 }
 
 static void
-background_configure(struct weston_surface *es, int32_t sx, int32_t sy)
+background_committed(struct weston_surface *es, int32_t sx, int32_t sy)
 {
-	struct desktop_shell *shell = es->configure_private;
+	struct desktop_shell *shell = es->committed_private;
 	struct weston_view *view;
 
 	view = container_of(es->views.next, struct weston_view, surface_link);
@@ -4435,7 +4435,7 @@
 	struct shell_output *sh_output;
 	struct weston_view *view, *next;
 
-	if (surface->configure) {
+	if (surface->committed) {
 		wl_resource_post_error(surface_resource,
 				       WL_DISPLAY_ERROR_INVALID_OBJECT,
 				       "surface role already assigned");
@@ -4446,8 +4446,8 @@
 		weston_view_destroy(view);
 	view = weston_view_create(surface);
 
-	surface->configure = background_configure;
-	surface->configure_private = shell;
+	surface->committed = background_committed;
+	surface->committed_private = shell;
 	weston_surface_set_label_func(surface, background_get_label);
 	surface->output = wl_resource_get_user_data(output_resource);
 	view->output = surface->output;
@@ -4471,9 +4471,9 @@
 }
 
 static void
-panel_configure(struct weston_surface *es, int32_t sx, int32_t sy)
+panel_committed(struct weston_surface *es, int32_t sx, int32_t sy)
 {
-	struct desktop_shell *shell = es->configure_private;
+	struct desktop_shell *shell = es->committed_private;
 	struct weston_view *view;
 
 	view = container_of(es->views.next, struct weston_view, surface_link);
@@ -4504,7 +4504,7 @@
 	struct weston_view *view, *next;
 	struct shell_output *sh_output;
 
-	if (surface->configure) {
+	if (surface->committed) {
 		wl_resource_post_error(surface_resource,
 				       WL_DISPLAY_ERROR_INVALID_OBJECT,
 				       "surface role already assigned");
@@ -4515,8 +4515,8 @@
 		weston_view_destroy(view);
 	view = weston_view_create(surface);
 
-	surface->configure = panel_configure;
-	surface->configure_private = shell;
+	surface->committed = panel_committed;
+	surface->committed_private = shell;
 	weston_surface_set_label_func(surface, panel_get_label);
 	surface->output = wl_resource_get_user_data(output_resource);
 	view->output = surface->output;
@@ -4539,9 +4539,9 @@
 }
 
 static void
-lock_surface_configure(struct weston_surface *surface, int32_t sx, int32_t sy)
+lock_surface_committed(struct weston_surface *surface, int32_t sx, int32_t sy)
 {
-	struct desktop_shell *shell = surface->configure_private;
+	struct desktop_shell *shell = surface->committed_private;
 	struct weston_view *view;
 
 	view = container_of(surface->views.next, struct weston_view, surface_link);
@@ -4592,8 +4592,8 @@
 		      &shell->lock_surface_listener);
 
 	weston_view_create(surface);
-	surface->configure = lock_surface_configure;
-	surface->configure_private = shell;
+	surface->committed = lock_surface_committed;
+	surface->committed_private = shell;
 	weston_surface_set_label_func(surface, lock_surface_get_label);
 }
 
@@ -5210,7 +5210,7 @@
 
 /* no-op func for checking black surface */
 static void
-black_surface_configure(struct weston_surface *es, int32_t sx, int32_t sy)
+black_surface_committed(struct weston_surface *es, int32_t sx, int32_t sy)
 {
 }
 
@@ -5219,9 +5219,9 @@
 {
 	struct weston_surface *surface = view->surface;
 
-	if (surface->configure == black_surface_configure) {
+	if (surface->committed == black_surface_committed) {
 		if (fs_view)
-			*fs_view = surface->configure_private;
+			*fs_view = surface->committed_private;
 		return true;
 	}
 	return false;
@@ -5779,7 +5779,7 @@
 }
 
 static void
-shell_surface_configure(struct weston_surface *es, int32_t sx, int32_t sy)
+shell_surface_committed(struct weston_surface *es, int32_t sx, int32_t sy)
 {
 	struct shell_surface *shsurf = get_shell_surface(es);
 	struct desktop_shell *shell;