kiwmi/include/desktop/desktop.h

44 lines
1.3 KiB
C
Raw Normal View History

2019-03-17 19:04:52 +00:00
/* Copyright (c), Charlotte Meyer <dev@buffet.sh>
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
* You can obtain one at https://mozilla.org/MPL/2.0/.
*/
#ifndef KIWMI_DESKTOP_DESKTOP_H
#define KIWMI_DESKTOP_DESKTOP_H
#include <wayland-server.h>
struct kiwmi_desktop {
struct wlr_compositor *compositor;
struct wlr_xdg_shell *xdg_shell;
2020-01-21 19:47:51 +00:00
struct wlr_xdg_decoration_manager_v1 *xdg_decoration_manager;
2020-01-15 20:30:37 +00:00
struct wlr_layer_shell_v1 *layer_shell;
2019-03-17 19:04:52 +00:00
struct wlr_data_device_manager *data_device_manager;
struct wlr_output_layout *output_layout;
struct wl_list outputs; // struct kiwmi_output::link
2020-01-18 19:38:47 +00:00
struct wl_list views; // struct kiwmi_view::link
2019-03-17 19:04:52 +00:00
2021-08-13 08:36:00 +00:00
float bg_color[4];
struct wl_listener xdg_shell_new_surface;
2020-01-21 19:47:51 +00:00
struct wl_listener xdg_toplevel_new_decoration;
2020-01-15 20:30:37 +00:00
struct wl_listener layer_shell_new_surface;
2019-03-17 19:04:52 +00:00
struct wl_listener new_output;
2020-01-01 18:13:24 +00:00
struct {
2020-01-06 18:25:46 +00:00
struct wl_signal new_output;
2020-01-01 18:13:24 +00:00
struct wl_signal view_map;
2021-08-01 21:58:07 +00:00
struct wl_signal request_active_output;
2020-01-01 18:13:24 +00:00
} events;
2019-03-17 19:04:52 +00:00
};
bool desktop_init(struct kiwmi_desktop *desktop);
2020-01-15 20:52:26 +00:00
void desktop_fini(struct kiwmi_desktop *desktop);
2019-03-17 19:04:52 +00:00
2021-08-01 21:58:07 +00:00
struct kiwmi_server;
struct kiwmi_output *desktop_active_output(struct kiwmi_server *server);
2019-03-17 19:04:52 +00:00
#endif /* KIWMI_DESKTOP_DESKTOP_H */