diff options
author | Drew DeVault <sir@cmpwn.com> | 2018-04-05 12:22:19 -0400 |
---|---|---|
committer | Drew DeVault <sir@cmpwn.com> | 2018-04-05 12:40:30 -0400 |
commit | abfe7923c45c2a1bdb155279b922b112111f3124 (patch) | |
tree | e162c702d7df17a13a56bf3fcd7cf7657793d8e1 /include/wlr | |
parent | 9a30a4f557c895e3d9ed9be19813ce43f05e00cb (diff) |
Add wlr_xdg_output_manager
Diffstat (limited to 'include/wlr')
-rw-r--r-- | include/wlr/types/wlr_output_layout.h | 5 | ||||
-rw-r--r-- | include/wlr/types/wlr_xdg_output.h | 32 |
2 files changed, 37 insertions, 0 deletions
diff --git a/include/wlr/types/wlr_output_layout.h b/include/wlr/types/wlr_output_layout.h index 3c150fc0..f2f6e44b 100644 --- a/include/wlr/types/wlr_output_layout.h +++ b/include/wlr/types/wlr_output_layout.h @@ -32,6 +32,11 @@ struct wlr_output_layout_output { } events; }; +/** + * Creates a wlr_output_layout, which can be used to describing outputs in + * physical space relative to one another, and perform various useful operations + * on that state. + */ struct wlr_output_layout *wlr_output_layout_create(); void wlr_output_layout_destroy(struct wlr_output_layout *layout); diff --git a/include/wlr/types/wlr_xdg_output.h b/include/wlr/types/wlr_xdg_output.h new file mode 100644 index 00000000..27dad2b8 --- /dev/null +++ b/include/wlr/types/wlr_xdg_output.h @@ -0,0 +1,32 @@ +#ifndef WLR_TYPES_WLR_XDG_OUTPUT_H +#define WLR_TYPES_WLR_XDG_OUTPUT_H +#include <wayland-server.h> +#include <wlr/types/wlr_output_layout.h> + +struct wlr_xdg_output { + struct wl_list link; + struct wl_list resources; + + struct wlr_xdg_output_manager *manager; + struct wlr_output_layout_output *layout_output; + + struct wl_listener destroy; +}; + +struct wlr_xdg_output_manager { + struct wl_global *global; + + struct wlr_output_layout *layout; + + struct wl_list outputs; + + struct wl_listener layout_add; + struct wl_listener layout_change; + struct wl_listener layout_destroy; +}; + +struct wlr_xdg_output_manager *wlr_xdg_output_manager_create( + struct wl_display *display, struct wlr_output_layout *layout); +void wlr_xdg_output_manager_destroy(struct wlr_xdg_output_manager *manager); + +#endif |