Handle window events only once visible

This will avoid corner cases where we need to resize while no frame has
been received yet.
android12_nosecure
Romain Vimont 3 years ago
parent a566635c43
commit 626094ad13

@ -184,7 +184,9 @@ handle_event(SDL_Event *event, const struct scrcpy_options *options) {
}
break;
case SDL_WINDOWEVENT:
screen_handle_window_event(&screen, &event->window);
if (screen.has_frame) {
screen_handle_window_event(&screen, &event->window);
}
break;
case SDL_TEXTINPUT:
if (!options->control) {

Loading…
Cancel
Save