mirror of
https://gitlab.freedesktop.org/wlroots/wlroots.git
synced 2026-04-19 06:47:02 -04:00
wlr_mirror: replace wlr_output->mirror_dst with wlr_addon
This commit is contained in:
parent
392dde7bed
commit
eac618687b
5 changed files with 53 additions and 6 deletions
13
util/addon.c
13
util/addon.c
|
|
@ -45,3 +45,16 @@ struct wlr_addon *wlr_addon_find(struct wlr_addon_set *set, const void *owner,
|
|||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void wlr_addon_find_all(struct wl_array *all, struct wlr_addon_set *set,
|
||||
const struct wlr_addon_interface *impl) {
|
||||
wl_array_init(all);
|
||||
struct wlr_addon *addon;
|
||||
wl_list_for_each(addon, &set->addons, link) {
|
||||
if (addon->impl == impl) {
|
||||
struct wlr_addon **addon_ptr = wl_array_add(all, sizeof(addon_ptr));
|
||||
*addon_ptr = addon;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue