2015-11-19 03:01:22 +00:00
|
|
|
#ifndef _SWAY_EXTENSIONS_H
|
|
|
|
#define _SWAY_EXTENSIONS_H
|
|
|
|
|
2015-12-10 22:04:09 +00:00
|
|
|
#include <wayland-server.h>
|
2015-12-03 13:35:22 +00:00
|
|
|
#include <wlc/wlc-wayland.h>
|
2015-11-29 17:03:13 +00:00
|
|
|
#include "wayland-desktop-shell-server-protocol.h"
|
2015-11-19 03:14:57 +00:00
|
|
|
#include "list.h"
|
|
|
|
|
|
|
|
struct background_config {
|
|
|
|
wlc_handle output;
|
2015-11-19 12:23:11 +00:00
|
|
|
wlc_resource surface;
|
2015-12-20 11:42:10 +00:00
|
|
|
// we need the wl_resource of the surface in the destructor
|
|
|
|
struct wl_resource *wl_surface_res;
|
2015-11-19 03:14:57 +00:00
|
|
|
};
|
|
|
|
|
2015-11-29 17:03:13 +00:00
|
|
|
struct panel_config {
|
2015-12-20 11:49:11 +00:00
|
|
|
// wayland resource used in callbacks, is used to track this panel
|
|
|
|
struct wl_resource *wl_resource;
|
2015-11-29 17:03:13 +00:00
|
|
|
wlc_handle output;
|
|
|
|
wlc_resource surface;
|
2015-12-20 11:42:10 +00:00
|
|
|
// we need the wl_resource of the surface in the destructor
|
|
|
|
struct wl_resource *wl_surface_res;
|
2015-12-20 11:49:11 +00:00
|
|
|
enum desktop_shell_panel_position panel_position;
|
2015-11-29 17:03:13 +00:00
|
|
|
};
|
|
|
|
|
2015-11-19 03:14:57 +00:00
|
|
|
struct desktop_shell_state {
|
|
|
|
list_t *backgrounds;
|
2015-11-29 17:03:13 +00:00
|
|
|
list_t *panels;
|
2015-12-18 13:49:04 +00:00
|
|
|
list_t *lock_surfaces;
|
|
|
|
bool is_locked;
|
2015-11-19 03:14:57 +00:00
|
|
|
};
|
|
|
|
|
2015-12-03 13:35:22 +00:00
|
|
|
struct swaylock_state {
|
|
|
|
bool active;
|
|
|
|
wlc_handle output;
|
|
|
|
wlc_resource surface;
|
|
|
|
};
|
|
|
|
|
2015-11-19 03:14:57 +00:00
|
|
|
extern struct desktop_shell_state desktop_shell;
|
|
|
|
|
2015-11-19 03:01:22 +00:00
|
|
|
void register_extensions(void);
|
|
|
|
|
|
|
|
#endif
|