     # Set defaults
     {
       @filename
+      @previewImage = $('.avatar-image .avatar')
       @form = @fileInput.parents('form')
       @modalCrop = '.modal-profile-crop'
+      @exportWidth = 200
+      @exportHeight = 200
+      @cropBoxWidth = 200
+      @cropBoxHeight = 200
 
       # Button where user clicks to open file dialog
       # If not passed as argument let's pick a default one

    @fileInput.trigger('click')

  onModalShow: =>
    @modalCropImg.cropper(
      viewMode: 1
      center: false

      array.push(binary.charCodeAt(k))
    new Blob([new Uint8Array(array)], type: 'image/png')

  setPreview: ->
    @previewImage.attr('src', @dataURL)

  setBlob: ->
    @dataURL = @modalCropImg.cropper('getCroppedCanvas',
        width: 200
        height: 200
      ).toDataURL('image/png')
    @croppedImageBlob = @dataURLtoBlob(@dataURL)

  getBlob: ->
    @croppedImageBlob
