output: damage whole output when fullscreen surface size changes

This commit is contained in:
emersion 2018-01-30 22:06:10 +01:00
parent a295c805c4
commit edb4c8d858
No known key found for this signature in database
GPG Key ID: 0FDE7BE0E88F5E48
2 changed files with 9 additions and 0 deletions

View File

@ -82,6 +82,7 @@ struct wlr_output {
struct wlr_surface *fullscreen_surface;
struct wl_listener fullscreen_surface_commit;
struct wl_listener fullscreen_surface_destroy;
int fullscreen_width, fullscreen_height;
struct wl_list cursors; // wlr_output_cursor::link
struct wlr_output_cursor *hardware_cursor;

View File

@ -594,6 +594,14 @@ static void output_fullscreen_surface_handle_commit(
fullscreen_surface_commit);
struct wlr_surface *surface = output->fullscreen_surface;
if (output->fullscreen_width != surface->current->width ||
output->fullscreen_height != surface->current->height) {
output->fullscreen_width = surface->current->width;
output->fullscreen_height = surface->current->height;
output_damage_whole(output);
return;
}
struct wlr_box box;
output_fullscreen_surface_get_box(output, surface, &box);