Added some basic image loading

Made thumbnails work when clicked on and added algorithm to calculate
the width of the thumbnail list