Bug 983172 - Parsing jpeg header information for downsampling the image for thumbnail

- Use image_utils lib for generating the thumbnail
- Use fixed thumbnail size and update the styling
Mmm, don't have much ideas too, only something like below, but I'm in doubt that it's any better than current solution :) So up to you!
```
var thumbnailPromise = this._attachment.type === 'img' &&
      this._attachment.size < MAX_THUMBNAIL_GENERATION_SIZE ?
        this.getThumbnail() : Promise.reject();

    return thumbnailPromise.
      then(function(url) {
        return {
          markup: this._getBaseMarkup('attachment-preview-tmpl'),
          cssClass: 'preview',
          url: url
        };
      }.bind(this)).
      catch(function(error) {
        return {
          markup: this._getBaseMarkup('attachment-nopreview-tmpl', !!error),
          cssClass: 'nopreview'
        };
      }.bind(this)).
      then(function(data) {
        attachmentContainer.classList.add(data.cssClass);

        return this._renderer.renderTo(data.markup, attachmentContainer).
          then(function(contentContainer) {
            // Since content container may differ from attachment container (
            // e.g. attachment container is an iframe and content container is
            // "body" element inside iframe), preview class should be applied to
            // both to have effect.
            contentContainer.classList.add(data.cssClass);

            var thumbnailNode = contentContainer.querySelector('.thumbnail');
            if (thumbnailNode) {
              thumbnailNode.style.backgroundImage =
                'url("' + data.url + '")';
            }
          });
      }.bind(this));
```