         provider: @props.provider
       @props.dialog.callback metadata
       @props.close()
+
+      # return value indicates whether to trigger href
+      return @state.supportsDownloadAttribute
     else
       e?.preventDefault()
     return

  render: ->
    confirmDisabled = @confirmDisabled()

    (div {className: 'dialogTab localFileSave'},
      (input {type: 'text', ref: 'filename', value: @state.filename, placeholder: (tr "~FILE_DIALOG.FILENAME"), onChange: @filenameChanged, onKeyDown: @watchForEnter}),
      (div {className: 'saveArea'},

      )
      div({className: 'note'}, tr('~FILE_DIALOG.DOWNLOAD_NOTE', {download: tr('~FILE_DIALOG.DOWNLOAD')}))
      (div {className: 'buttons'},
        if @state.supportsDownloadAttribute then downloadAnchor else downloadButton
        (button {onClick: @cancel}, (tr "~FILE_DIALOG.CANCEL"))
      )
    )