Added images loaded script for masonry

Added in order to stop the image performance items from overlapping when
first opening the gallery.