fix resize issue after exiting fullscreen with ESC key