[PATCH weston 2/3] Send the new wl_output.name event when binding an output

Neil Roberts neil at linux.intel.com
Wed Apr 30 04:26:24 PDT 2014


This version for the wl_output interface has been changed to 3 and it
now sends out the name event when a client binds an output.
---
 src/compositor.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/src/compositor.c b/src/compositor.c
index ee8dc24..6a333df 100644
--- a/src/compositor.c
+++ b/src/compositor.c
@@ -3081,6 +3081,9 @@ bind_output(struct wl_client *client,
 				    mode->refresh);
 	}
 
+	if (version >= 3 && output->name)
+		wl_output_send_name(resource, output->name);
+
 	if (version >= 2)
 		wl_output_send_done(resource);
 }
@@ -3321,7 +3324,7 @@ weston_output_init(struct weston_output *output, struct weston_compositor *c,
 	output->compositor->output_id_pool |= 1 << output->id;
 
 	output->global =
-		wl_global_create(c->wl_display, &wl_output_interface, 2,
+		wl_global_create(c->wl_display, &wl_output_interface, 3,
 				 output, bind_output);
 	wl_signal_emit(&c->output_created_signal, output);
 }
-- 
1.9.0



More information about the wayland-devel mailing list