mirror of
https://gitlab.freedesktop.org/wlroots/wlroots.git
synced 2025-11-25 06:59:42 -05:00
Add support for wlr-output-management-unstable-v1
This commit is contained in:
parent
b6d0de177a
commit
3a233b3fcc
6 changed files with 928 additions and 0 deletions
|
|
@ -23,6 +23,7 @@ install_headers(
|
|||
'wlr_matrix.h',
|
||||
'wlr_output_damage.h',
|
||||
'wlr_output_layout.h',
|
||||
'wlr_output_management_v1.h',
|
||||
'wlr_output.h',
|
||||
'wlr_pointer_constraints_v1.h',
|
||||
'wlr_pointer_gestures_v1.h',
|
||||
|
|
|
|||
66
include/wlr/types/wlr_output_management_v1.h
Normal file
66
include/wlr/types/wlr_output_management_v1.h
Normal file
|
|
@ -0,0 +1,66 @@
|
|||
/*
|
||||
* This an unstable interface of wlroots. No guarantees are made regarding the
|
||||
* future consistency of this API.
|
||||
*/
|
||||
#ifndef WLR_USE_UNSTABLE
|
||||
#error "Add -DWLR_USE_UNSTABLE to enable unstable wlroots features"
|
||||
#endif
|
||||
|
||||
#ifndef WLR_TYPES_WLR_OUTPUT_MANAGEMENT_V1_H
|
||||
#define WLR_TYPES_WLR_OUTPUT_MANAGEMENT_V1_H
|
||||
|
||||
#include <wayland-server.h>
|
||||
#include <wlr/types/wlr_output.h>
|
||||
|
||||
struct wlr_output_configuration_v1;
|
||||
|
||||
struct wlr_output_manager_v1 {
|
||||
struct wl_display *display;
|
||||
struct wl_global *global;
|
||||
struct wl_list resources;
|
||||
|
||||
struct wlr_output_configuration_v1 *current;
|
||||
|
||||
struct {
|
||||
struct wl_signal destroy;
|
||||
} events;
|
||||
|
||||
struct wl_listener display_destroy;
|
||||
|
||||
void *data;
|
||||
};
|
||||
|
||||
// TODO: split this into multiple structs (state + output_head + output_configuration_head)
|
||||
struct wlr_output_configuration_head_v1 {
|
||||
struct wlr_output_configuration_v1 *config;
|
||||
struct wlr_output *output;
|
||||
struct wl_list link;
|
||||
|
||||
// for current config only
|
||||
struct wl_list resources;
|
||||
|
||||
bool enabled;
|
||||
|
||||
struct wl_listener output_destroy;
|
||||
};
|
||||
|
||||
struct wlr_output_configuration_v1 {
|
||||
struct wl_list heads;
|
||||
uint32_t serial;
|
||||
};
|
||||
|
||||
struct wlr_output_manager_v1 *wlr_output_manager_v1_create(
|
||||
struct wl_display *display);
|
||||
void wlr_output_manager_v1_set_configuration(
|
||||
struct wlr_output_manager_v1 *manager,
|
||||
struct wlr_output_configuration_v1 *config);
|
||||
|
||||
struct wlr_output_configuration_v1 *wlr_output_configuration_v1_create(void);
|
||||
void wlr_output_configuration_v1_destroy(
|
||||
struct wlr_output_configuration_v1 *config);
|
||||
|
||||
struct wlr_output_configuration_head_v1 *
|
||||
wlr_output_configuration_head_v1_create(
|
||||
struct wlr_output_configuration_v1 *config, struct wlr_output *output);
|
||||
|
||||
#endif
|
||||
Loading…
Add table
Add a link
Reference in a new issue