aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoremersion <contact@emersion.fr>2018-01-28 12:14:23 +0100
committeremersion <contact@emersion.fr>2018-01-28 12:14:23 +0100
commit692d33bf8b752cc3b8a0b7f2b29c2b49dd4f718b (patch)
treef81e45faf8e001a11f1e315870334ba50717dd79
parent485aa8746865cc34ead2ef7e6cd76ed98ce89c47 (diff)
rootston: fix clipped SSD for rotated views
-rw-r--r--rootston/output.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/rootston/output.c b/rootston/output.c
index a31462be..f0710b11 100644
--- a/rootston/output.c
+++ b/rootston/output.c
@@ -287,10 +287,13 @@ static void render_decorations(struct roots_view *view,
struct wlr_box box;
get_decoration_box(view, output, &box);
+ struct wlr_box rotated;
+ wlr_box_rotated_bounds(&box, -view->rotation, &rotated);
+
pixman_region32_t damage;
pixman_region32_init(&damage);
- pixman_region32_union_rect(&damage, &damage, box.x, box.y,
- box.width, box.height);
+ pixman_region32_union_rect(&damage, &damage, rotated.x, rotated.y,
+ rotated.width, rotated.height);
pixman_region32_intersect(&damage, &damage, data->damage);
bool damaged = pixman_region32_not_empty(&damage);
if (!damaged) {