fix preload when page is resized