handles multiple images' preloading using xhr2