Skip to content
This repository has been archived by the owner on Nov 1, 2021. It is now read-only.

layer shell: rename popup iterator for consistency #2617

Merged
merged 1 commit into from
Jan 12, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 8 additions & 2 deletions include/wlr/types/wlr_layer_shell_v1.h
Original file line number Diff line number Diff line change
Expand Up @@ -138,8 +138,14 @@ struct wlr_layer_surface_v1 *wlr_layer_surface_v1_from_wlr_surface(
void wlr_layer_surface_v1_for_each_surface(struct wlr_layer_surface_v1 *surface,
wlr_surface_iterator_func_t iterator, void *user_data);

/* Calls the iterator function for each popup of this surface */
void wlr_layer_surface_v1_for_each_popup(struct wlr_layer_surface_v1 *surface,
/**
* Call `iterator` on each popup's surface and popup's subsurface in the
* layer surface's tree, with the surfaces's position relative to the root
* layer surface. The function is called from root to leaves (in rendering
* order).
*/
void wlr_layer_surface_v1_for_each_popup_surface(
struct wlr_layer_surface_v1 *surface,
wlr_surface_iterator_func_t iterator, void *user_data);

/**
Expand Down
4 changes: 2 additions & 2 deletions types/wlr_layer_shell_v1.c
Original file line number Diff line number Diff line change
Expand Up @@ -533,10 +533,10 @@ static void layer_surface_iterator(struct wlr_surface *surface,
void wlr_layer_surface_v1_for_each_surface(struct wlr_layer_surface_v1 *surface,
wlr_surface_iterator_func_t iterator, void *user_data) {
wlr_surface_for_each_surface(surface->surface, iterator, user_data);
wlr_layer_surface_v1_for_each_popup(surface, iterator, user_data);
wlr_layer_surface_v1_for_each_popup_surface(surface, iterator, user_data);
}

void wlr_layer_surface_v1_for_each_popup(struct wlr_layer_surface_v1 *surface,
void wlr_layer_surface_v1_for_each_popup_surface(struct wlr_layer_surface_v1 *surface,
wlr_surface_iterator_func_t iterator, void *user_data){
struct wlr_xdg_popup *popup_state;
wl_list_for_each(popup_state, &surface->popups, link) {
Expand Down