aboutsummaryrefslogtreecommitdiff
path: root/include/wlr
diff options
context:
space:
mode:
authorAlexander Orzechowski <orzechowski.alexander@gmail.com>2022-06-05 13:06:18 -0400
committerSimon Ser <contact@emersion.fr>2023-05-30 15:40:41 +0000
commit88f80c4a7caacc0263fad27173a2abd56b482c51 (patch)
treef143355ab1c1142d7fd1c0b5e09c5d8340c5743a /include/wlr
parent61c157269e1ac7ef5323a54609514f2d76e79afe (diff)
wlr_scene: Make scene_tree_from_node public
This is to allow for compositors that want to be more implicit about how their scene is organized. Such a compositor may want to walk up at a certain scene node to find something such as a surface to focus on.
Diffstat (limited to 'include/wlr')
-rw-r--r--include/wlr/types/wlr_scene.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/wlr/types/wlr_scene.h b/include/wlr/types/wlr_scene.h
index ca4641fa..aa371d13 100644
--- a/include/wlr/types/wlr_scene.h
+++ b/include/wlr/types/wlr_scene.h
@@ -324,6 +324,12 @@ struct wlr_scene_surface *wlr_scene_surface_create(struct wlr_scene_tree *parent
struct wlr_scene_buffer *wlr_scene_buffer_from_node(struct wlr_scene_node *node);
/**
+ * If this node represents a wlr_scene_tree, that tree will be returned. It
+ * is not legal to feed a node that does not represent a wlr_scene_tree.
+ */
+struct wlr_scene_tree *wlr_scene_tree_from_node(struct wlr_scene_node *node);
+
+/**
* If this buffer is backed by a surface, then the struct wlr_scene_surface is
* returned. If not, NULL will be returned.
*/