fullscreen-shell-v1: initial protocol implementation

This commit is contained in:
emersion 2019-01-06 12:08:45 +01:00
parent aebd74243f
commit 86f263a0b8
No known key found for this signature in database
GPG key ID: 0FDE7BE0E88F5E48
7 changed files with 434 additions and 9 deletions

View file

@ -6,6 +6,7 @@ install_headers(
'wlr_data_device.h',
'wlr_export_dmabuf_v1.h',
'wlr_foreign_toplevel_management_v1.h',
'wlr_fullscreen_shell_v1.h',
'wlr_gamma_control_v1.h',
'wlr_gamma_control.h',
'wlr_gtk_primary_selection.h',
@ -22,8 +23,8 @@ install_headers(
'wlr_output_damage.h',
'wlr_output_layout.h',
'wlr_output.h',
'wlr_pointer.h',
'wlr_pointer_constraints_v1.h',
'wlr_pointer.h',
'wlr_presentation_time.h',
'wlr_primary_selection.h',
'wlr_region.h',

View file

@ -0,0 +1,41 @@
/*
* 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_FULLSCREEN_SHELL_V1_H
#define WLR_TYPES_WLR_FULLSCREEN_SHELL_V1_H
#include <wayland-server.h>
#include "fullscreen-shell-unstable-v1-protocol.h"
struct wlr_fullscreen_shell_v1 {
struct wl_global *global;
struct wl_list resources;
struct {
struct wl_signal destroy;
// wlr_fullscreen_shell_v1_present_surface_event
struct wl_signal present_surface;
} events;
struct wl_listener display_destroy;
void *data;
};
struct wlr_fullscreen_shell_v1_present_surface_event {
struct wl_client *client;
struct wlr_surface *surface; // can be NULL
enum zwp_fullscreen_shell_v1_present_method method;
struct wlr_output *output; // can be NULL
};
struct wlr_fullscreen_shell_v1 *wlr_fullscreen_shell_v1_create(
struct wl_display *display);
void wlr_fullscreen_shell_v1_destroy(struct wlr_fullscreen_shell_v1 *shell);
#endif