Add CSD to border modes

This commit is contained in:
Ryan Dwyer 2018-09-23 23:24:34 +10:00
parent 0bc9dc192f
commit 97c0a56ce3
11 changed files with 94 additions and 81 deletions

View file

@ -5,6 +5,7 @@
struct sway_server_decoration {
struct wlr_server_decoration *wlr_server_decoration;
struct sway_view *view;
struct wl_list link;
struct wl_listener destroy;

View file

@ -28,6 +28,7 @@ enum sway_container_border {
B_NONE,
B_PIXEL,
B_NORMAL,
B_CSD,
};
struct sway_root;
@ -63,7 +64,6 @@ struct sway_container_state {
bool border_bottom;
bool border_left;
bool border_right;
bool using_csd;
};
struct sway_container {

View file

@ -60,6 +60,7 @@ struct sway_view {
struct sway_container *container; // NULL if unmapped and transactions finished
struct wlr_surface *surface; // NULL for unmapped views
struct sway_server_decoration *decoration;
pid_t pid;
@ -81,7 +82,6 @@ struct sway_view {
bool border_bottom;
bool border_left;
bool border_right;
bool using_csd;
struct timespec urgent;
bool allow_request_urgent;
@ -268,6 +268,8 @@ void view_set_activated(struct sway_view *view, bool activated);
*/
void view_request_activate(struct sway_view *view);
void view_set_csd(struct sway_view *view, bool enabled);
void view_set_tiled(struct sway_view *view, bool tiled);
void view_close(struct sway_view *view);