aboutsummaryrefslogtreecommitdiff
path: root/sway/tree
diff options
context:
space:
mode:
authorDrew DeVault <sir@cmpwn.com>2018-03-28 16:38:11 -0400
committerDrew DeVault <sir@cmpwn.com>2018-03-28 16:42:13 -0400
commit68cfa7ef6705c530ff28d9754c5b6cab7b429150 (patch)
tree0c25eb44f1285f2522b6a5f014276239cfa6ae3f /sway/tree
parent0c8a64942e087038806b353949c900e03fd764a8 (diff)
downloadsway-68cfa7ef6705c530ff28d9754c5b6cab7b429150.tar.xz
Render layer surfaces and respect exclusive zone
Diffstat (limited to 'sway/tree')
-rw-r--r--sway/tree/container.c4
-rw-r--r--sway/tree/layout.c11
2 files changed, 10 insertions, 5 deletions
diff --git a/sway/tree/container.c b/sway/tree/container.c
index 705221d7..bbafe9ec 100644
--- a/sway/tree/container.c
+++ b/sway/tree/container.c
@@ -254,7 +254,9 @@ swayc_t *destroy_output(swayc_t *output) {
}
}
- wl_list_remove(&output->sway_output->output_destroy.link);
+ wl_list_remove(&output->sway_output->frame.link);
+ wl_list_remove(&output->sway_output->destroy.link);
+ wl_list_remove(&output->sway_output->mode.link);
wlr_log(L_DEBUG, "OUTPUT: Destroying output '%s'", output->name);
free_swayc(output);
diff --git a/sway/tree/layout.c b/sway/tree/layout.c
index 3d04a1a7..de9e7b58 100644
--- a/sway/tree/layout.c
+++ b/sway/tree/layout.c
@@ -204,10 +204,13 @@ void arrange_windows(swayc_t *container, double width, double height) {
case C_WORKSPACE:
{
swayc_t *output = swayc_parent_by_type(container, C_OUTPUT);
- container->width = output->width;
- container->height = output->height;
- container->x = x;
- container->y = y;
+ struct wlr_box *area = &output->sway_output->usable_area;
+ wlr_log(L_DEBUG, "Usable area for ws: %dx%d@%d,%d",
+ area->width, area->height, area->x, area->y);
+ container->width = area->width;
+ container->height = area->height;
+ container->x = x = area->x;
+ container->y = y = area->y;
wlr_log(L_DEBUG, "Arranging workspace '%s' at %f, %f",
container->name, container->x, container->y);
}