[PATCH 2/6] Add weston_randr definition and randr_backend intreface

Quanxian Wang quanxian.wang at intel.com
Wed Feb 26 19:28:01 PST 2014


Signed-off-by: Quanxian Wang <quanxian.wang at intel.com>
Reviewed-by: Zhang, Xiong Y <xiong.y.zhang at intel.com>
---
 src/compositor.h | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

diff --git a/src/compositor.h b/src/compositor.h
index 22a485f..6bc000f 100644
--- a/src/compositor.h
+++ b/src/compositor.h
@@ -172,6 +172,15 @@ enum weston_mode_switch_op {
 	WESTON_MODE_SWITCH_RESTORE_NATIVE
 };
 
+struct weston_randr {
+	struct weston_compositor *compositor;
+	struct wl_global *global;
+	struct wl_resource *resource;
+	void (*get_disoutputs)(struct weston_compositor *ec,
+			       char *ret_str);
+	void (*destroy)(struct weston_compositor *ec);
+};
+
 struct weston_output {
 	uint32_t id;
 	char *name;
@@ -632,6 +641,7 @@ struct weston_compositor {
 
 	/* Raw keyboard processing (no libxkbcommon initialization or handling) */
 	int use_xkbcommon;
+	struct weston_randr *randr;
 };
 
 struct weston_buffer {
@@ -1254,6 +1264,10 @@ weston_compositor_xkb_init(struct weston_compositor *ec,
 void
 weston_compositor_xkb_destroy(struct weston_compositor *ec);
 
+/* define randr interface */
+int
+weston_randr_init(struct weston_randr *randr, struct weston_compositor *ec);
+
 /* String literal of spaces, the same width as the timestamp. */
 #define STAMP_SPACE "               "
 
-- 
1.8.1.2



More information about the wayland-devel mailing list