mirror of
https://github.com/swaywm/sway.git
synced 2025-11-08 13:29:50 -05:00
tree/container: introduce container_toplevel_ancestor helper
This allows us to not have to explicitly write the same while loop everywhere.
This commit is contained in:
parent
d7900c6e5e
commit
53dc83fb68
3 changed files with 19 additions and 17 deletions
|
|
@ -272,6 +272,13 @@ void container_set_fullscreen(struct sway_container *con,
|
|||
*/
|
||||
void container_fullscreen_disable(struct sway_container *con);
|
||||
|
||||
/**
|
||||
* Walk up the container tree branch starting at the given container, and return
|
||||
* its earliest ancestor.
|
||||
*/
|
||||
struct sway_container *container_toplevel_ancestor(
|
||||
struct sway_container *container);
|
||||
|
||||
/**
|
||||
* Return true if the container is floating, or a child of a floating split
|
||||
* container.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue