mirror of
https://gitlab.freedesktop.org/wlroots/wlroots.git
synced 2025-11-02 09:01:38 -05:00
Wire up layer surface resources to stubs
This commit is contained in:
parent
f29d8b55ae
commit
3ba57fccd1
3 changed files with 236 additions and 12 deletions
|
|
@ -1,5 +1,11 @@
|
|||
#ifndef WLR_TYPES_WLR_LAYER_SHELL_H
|
||||
#define WLR_TYPES_WLR_LAYER_SHELL_H
|
||||
#include <stdbool.h>
|
||||
#include <stdint.h>
|
||||
#include <wayland-server.h>
|
||||
#include <wlr/types/wlr_box.h>
|
||||
#include <wlr/types/wlr_surface.h>
|
||||
#include "wlr-layer-shell-unstable-v1-protocol.h"
|
||||
|
||||
struct wlr_layer_shell {
|
||||
struct wl_global *wl_global;
|
||||
|
|
@ -23,6 +29,50 @@ struct wlr_layer_client {
|
|||
struct wl_list link; // wlr_layer_shell::clients
|
||||
};
|
||||
|
||||
struct wlr_layer_surface_state {
|
||||
uint32_t anchor;
|
||||
uint32_t exclusive_zone;
|
||||
struct {
|
||||
uint32_t top, right, bottom, left;
|
||||
} margin;
|
||||
};
|
||||
|
||||
struct wlr_layer_surface_configure {
|
||||
struct wl_list link; // wlr_layer_surface::configure_list
|
||||
uint32_t serial;
|
||||
struct wlr_layer_surface_state *state;
|
||||
};
|
||||
|
||||
struct wlr_layer_surface {
|
||||
struct wlr_surface *surface;
|
||||
struct wlr_layer_client *client;
|
||||
struct wl_resource *resource;
|
||||
struct wl_list link; // wlr_layer_client:surfaces
|
||||
|
||||
const char *namespace;
|
||||
enum zwlr_layer_shell_v1_layer layer;
|
||||
|
||||
bool added, configured, mapped;
|
||||
uint32_t configure_serial;
|
||||
struct wl_event_source *configure_idle;
|
||||
uint32_t configure_next_serial;
|
||||
struct wl_list configure_list;
|
||||
|
||||
struct wlr_layer_surface_state next; // client protocol requests
|
||||
struct wlr_layer_surface_state pending; // our configure requests
|
||||
struct wlr_layer_surface_state current;
|
||||
|
||||
struct wl_listener surface_destroy_listener;
|
||||
|
||||
struct {
|
||||
struct wl_signal destroy;
|
||||
struct wl_signal map;
|
||||
struct wl_signal unmap;
|
||||
} events;
|
||||
|
||||
void *data;
|
||||
};
|
||||
|
||||
struct wlr_layer_shell *wlr_layer_shell_create(struct wl_display *display);
|
||||
void wlr_layer_shell_destroy(struct wlr_layer_shell *layer_shell);
|
||||
|
||||
|
|
|
|||
|
|
@ -79,7 +79,7 @@ struct wlr_xdg_toplevel {
|
|||
bool added;
|
||||
|
||||
struct wlr_xdg_toplevel_state next; // client protocol requests
|
||||
struct wlr_xdg_toplevel_state pending; // user configure requests
|
||||
struct wlr_xdg_toplevel_state pending; // our configure requests
|
||||
struct wlr_xdg_toplevel_state current;
|
||||
|
||||
char *title;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue