Skip to content

Commit

Permalink
Render screen on window restored
Browse files Browse the repository at this point in the history
It should not be necessary, since screen_render() is called just after
on SDL_WINDOWEVENT_EXPOSED, but in practice the window content might not
be correctly displayed on restored if a rotation occurred while
minimized.

Note that calling screen_render() twice in a row on
SDL_WINDOWEVENT_EXPOSED also "fixes" the issue.
  • Loading branch information
rom1v committed Jun 14, 2021
1 parent cd28945 commit 7343b23
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions app/src/screen.c
Original file line number Diff line number Diff line change
Expand Up @@ -726,6 +726,7 @@ screen_handle_event(struct screen *screen, SDL_Event *event) {
}
screen->maximized = false;
apply_pending_resize(screen);
screen_render(screen, true);
break;
}
return true;
Expand Down

0 comments on commit 7343b23

Please sign in to comment.