mirror of
https://gitlab.freedesktop.org/wlroots/wlroots.git
synced 2025-11-21 06:59:44 -05:00
xdg-shell-toplevel configure requests
This commit is contained in:
parent
45a3b761a6
commit
a0bdbc92ba
2 changed files with 299 additions and 48 deletions
|
|
@ -23,6 +23,9 @@ struct wlr_xdg_toplevel_v6_state {
|
|||
bool resizing;
|
||||
bool activated;
|
||||
|
||||
uint32_t width;
|
||||
uint32_t height;
|
||||
|
||||
uint32_t max_width;
|
||||
uint32_t max_height;
|
||||
|
||||
|
|
@ -31,17 +34,31 @@ struct wlr_xdg_toplevel_v6_state {
|
|||
};
|
||||
|
||||
struct wlr_xdg_toplevel_v6 {
|
||||
struct wlr_xdg_toplevel_v6_state next;
|
||||
struct wl_resource *resource;
|
||||
struct wlr_xdg_surface_v6 *base;
|
||||
struct wlr_xdg_toplevel_v6_state next; // client protocol requests
|
||||
struct wlr_xdg_toplevel_v6_state pending; // user configure requests
|
||||
struct wlr_xdg_toplevel_v6_state current;
|
||||
};
|
||||
|
||||
// TODO split up into toplevel and popup configure
|
||||
struct wlr_xdg_surface_v6_configure {
|
||||
struct wl_list link; // wlr_xdg_surface_v6::configure_list
|
||||
uint32_t serial;
|
||||
struct wlr_xdg_toplevel_v6_state *state;
|
||||
};
|
||||
|
||||
struct wlr_xdg_surface_v6 {
|
||||
struct wl_client *client;
|
||||
struct wl_resource *resource;
|
||||
struct wlr_surface *surface;
|
||||
struct wl_list link;
|
||||
enum wlr_xdg_surface_v6_role role;
|
||||
struct wlr_xdg_toplevel_v6 *toplevel_state;
|
||||
|
||||
struct wl_event_source *configure_idle;
|
||||
struct wl_list configure_list;
|
||||
|
||||
char *title;
|
||||
char *app_id;
|
||||
|
||||
|
|
@ -64,4 +81,38 @@ struct wlr_xdg_surface_v6 {
|
|||
struct wlr_xdg_shell_v6 *wlr_xdg_shell_v6_create(struct wl_display *display);
|
||||
void wlr_xdg_shell_v6_destroy(struct wlr_xdg_shell_v6 *xdg_shell);
|
||||
|
||||
/**
|
||||
* Request that this toplevel surface be the given size.
|
||||
*/
|
||||
void wlr_xdg_toplevel_v6_set_size(struct wlr_xdg_surface_v6 *surface,
|
||||
uint32_t width, uint32_t height);
|
||||
|
||||
/**
|
||||
* Request that this toplevel surface show itself in an activated or deactivated
|
||||
* state.
|
||||
*/
|
||||
void wlr_xdg_toplevel_v6_set_activated(struct wlr_xdg_surface_v6 *surface,
|
||||
bool activated);
|
||||
|
||||
/**
|
||||
* Request that this toplevel surface consider itself maximized or not
|
||||
* maximized.
|
||||
*/
|
||||
void wlr_xdg_toplevel_v6_set_maximized(struct wlr_xdg_surface_v6 *surface,
|
||||
bool maximized);
|
||||
|
||||
/**
|
||||
* Request that this toplevel surface consider itself fullscreen or not
|
||||
* fullscreen.
|
||||
*/
|
||||
void wlr_xdg_toplevel_v6_set_fullscreen(struct wlr_xdg_surface_v6 *surface,
|
||||
bool fullscreen);
|
||||
|
||||
/**
|
||||
* Request that this toplevel surface consider itself to be resizing or not
|
||||
* resizing.
|
||||
*/
|
||||
void wlr_xdg_toplevel_v6_set_resizing(struct wlr_xdg_surface_v6 *surface,
|
||||
bool resizing);
|
||||
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue