aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorDrew DeVault <sir@cmpwn.com>2017-08-09 11:32:02 -0400
committerGitHub <noreply@github.com>2017-08-09 11:32:02 -0400
commitdf378d32740495d33dc46e799a547adc9b9620e1 (patch)
tree969d1e4d3d557cdeaa6544ebf3ffd7b4579d5fbd /include
parent6345d6deeda014b8a95ef4a40eef938b552ff153 (diff)
parentfb58307a5006366e791c96491f855777a11fdf2c (diff)
Merge pull request #50 from nyorain/wl_surface
Add first wlr_surface example implementation
Diffstat (limited to 'include')
-rw-r--r--include/wlr/types/wlr_surface.h25
1 files changed, 25 insertions, 0 deletions
diff --git a/include/wlr/types/wlr_surface.h b/include/wlr/types/wlr_surface.h
new file mode 100644
index 00000000..88a9a4d8
--- /dev/null
+++ b/include/wlr/types/wlr_surface.h
@@ -0,0 +1,25 @@
+#ifndef _WLR_TYPES_WLR_SURFACE_H
+#define _WLR_TYPES_WLR_SURFACE_H
+
+#include <wayland-server.h>
+
+struct wlr_surface {
+ struct wl_resource *pending_buffer;
+ bool pending_attached;
+ bool attached; // whether the surface currently has a buffer attached
+
+ struct wlr_texture *texture;
+ const char *role; // the lifetime-bound role or null
+ struct wl_resource *resource;
+
+ struct {
+ struct wl_signal destroy;
+ struct wl_signal commit;
+ } signals;
+};
+
+struct wlr_renderer;
+struct wlr_surface *wlr_surface_create(struct wl_resource *res,
+ struct wlr_renderer *renderer);
+
+#endif