|
|
@ -169,14 +169,13 @@ static bool wlr_surface_update_size(struct wlr_surface *surface,
|
|
|
|
wl_list_init(&state->frame_callback_list);
|
|
|
|
wl_list_init(&state->frame_callback_list);
|
|
|
|
|
|
|
|
|
|
|
|
bool update_damage = false;
|
|
|
|
bool update_damage = false;
|
|
|
|
if (width < state->width) {
|
|
|
|
if (width != state->width || height != state->height) {
|
|
|
|
pixman_region32_union_rect(&state->surface_damage, &state->surface_damage,
|
|
|
|
// Damage the whole surface on resize
|
|
|
|
width, 0, state->width - width, state->height);
|
|
|
|
// This isn't in the spec, but Weston does it and QT expects it
|
|
|
|
update_damage = true;
|
|
|
|
pixman_region32_union_rect(&state->surface_damage,
|
|
|
|
}
|
|
|
|
&state->surface_damage, 0, 0, state->width, state->height);
|
|
|
|
if (height < state->height) {
|
|
|
|
pixman_region32_union_rect(&state->surface_damage,
|
|
|
|
pixman_region32_union_rect(&state->surface_damage, &state->surface_damage,
|
|
|
|
&state->surface_damage, 0, 0, width, height);
|
|
|
|
0, height, state->width, state->height - height);
|
|
|
|
|
|
|
|
update_damage = true;
|
|
|
|
update_damage = true;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|