moved spin and imagesLoaded to common