summaryrefslogtreecommitdiff
path: root/sway/desktop/layer_shell.c
diff options
context:
space:
mode:
Diffstat (limited to 'sway/desktop/layer_shell.c')
-rw-r--r--sway/desktop/layer_shell.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/sway/desktop/layer_shell.c b/sway/desktop/layer_shell.c
index bbc2e6f3..3bbc855d 100644
--- a/sway/desktop/layer_shell.c
+++ b/sway/desktop/layer_shell.c
@@ -334,6 +334,13 @@ static void handle_surface_commit(struct wl_listener *listener, void *data) {
bool extent_changed =
memcmp(&old_extent, &layer->extent, sizeof(struct wlr_box)) != 0;
if (extent_changed || layer_changed) {
+ int blur_size = layer->has_blur? config_get_blur_size(): 0;
+ int shadow_sigma = layer->has_shadow? config->shadow_blur_sigma: 0;
+ int effect_size = MAX(blur_size, shadow_sigma);
+ old_extent.x -= effect_size;
+ old_extent.y -= effect_size;
+ old_extent.width += effect_size * 2;
+ old_extent.height += effect_size * 2;
output_damage_box(output, &old_extent);
output_damage_surface(output, layer->geo.x, layer->geo.y,
layer_surface->surface, true);