Implemented Desandro's imagesLoaded plugin

to fix Safari/WebKit firing the window.onload event before images are
loaded