Change container_get_first_view signature

This will have the function stop the recusive calls as soon as
the first view is found - unlike before
This commit is contained in:
Fabian Specht 2024-01-12 21:23:08 +01:00
parent c2eaf01767
commit 88fb849e59
No known key found for this signature in database
GPG key ID: 8BD4621E4A78BA57
3 changed files with 15 additions and 8 deletions

View file

@ -164,8 +164,7 @@ struct sway_container *tiling_container_at(
struct sway_node *parent, double lx, double ly,
struct wlr_surface **surface, double *sx, double *sy);
void container_get_first_view(struct sway_container *container,
struct sway_container **view);
struct sway_container *container_get_first_view(struct sway_container *container);
void container_for_each_child(struct sway_container *container,
void (*f)(struct sway_container *container, void *data), void *data);