aboutsummaryrefslogtreecommitdiff
path: root/sway/desktop/layer_shell.c
diff options
context:
space:
mode:
authorDominique Martinet <asmadeus@codewreck.org>2018-06-30 14:00:24 +0900
committerDominique Martinet <asmadeus@codewreck.org>2018-06-30 22:31:14 +0900
commit9ea4cc13a0cf2d231c4e4c71aa674cd76831e6f9 (patch)
treea4f6056b5cfa80e065f366d20e1d97957d3ee393 /sway/desktop/layer_shell.c
parentd8c61c976372eedf271f505ffd82c461b6503f6f (diff)
sway views: add helpers to get view and layer from wlr_surface
Diffstat (limited to 'sway/desktop/layer_shell.c')
-rw-r--r--sway/desktop/layer_shell.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/sway/desktop/layer_shell.c b/sway/desktop/layer_shell.c
index ff37bbf1..de1fe349 100644
--- a/sway/desktop/layer_shell.c
+++ b/sway/desktop/layer_shell.c
@@ -307,6 +307,11 @@ static void handle_unmap(struct wl_listener *listener, void *data) {
unmap(sway_layer);
}
+struct sway_layer_surface *layer_from_wlr_layer_surface(
+ struct wlr_layer_surface *layer_surface) {
+ return layer_surface->data;
+}
+
void handle_layer_shell_surface(struct wl_listener *listener, void *data) {
struct wlr_layer_surface *layer_surface = data;
struct sway_server *server =