diff options
author | Harrison Healey <harrisonmhealey@gmail.com> | 2015-09-24 09:17:59 -0400 |
---|---|---|
committer | Harrison Healey <harrisonmhealey@gmail.com> | 2015-09-24 09:17:59 -0400 |
commit | 4f371254c68fe41365f3c03001743a035bc63384 (patch) | |
tree | 6bebdde639c6612eed317c951e59abdb596996a7 /web/react/components/file_upload.jsx | |
parent | 90d1f4c6a130deeb7685b86bcce44472f9c7ece5 (diff) | |
parent | ef8705ab6b9f11da77d8056e68b9fc2adb2ef496 (diff) | |
download | chat-4f371254c68fe41365f3c03001743a035bc63384.tar.gz chat-4f371254c68fe41365f3c03001743a035bc63384.tar.bz2 chat-4f371254c68fe41365f3c03001743a035bc63384.zip |
Merge pull request #771 from rgarmsen2295/plt-143
PLT-143 Support for text drag and drop
Diffstat (limited to 'web/react/components/file_upload.jsx')
-rw-r--r-- | web/react/components/file_upload.jsx | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/web/react/components/file_upload.jsx b/web/react/components/file_upload.jsx index 3cb284171..3dc4e5de2 100644 --- a/web/react/components/file_upload.jsx +++ b/web/react/components/file_upload.jsx @@ -110,7 +110,7 @@ export default class FileUpload extends React.Component { if (typeof files !== 'string' && files.length) { this.uploadFiles(files); } else { - this.props.onUploadError('Invalid file upload', -1); + this.props.onTextDrop(e.originalEvent.dataTransfer.getData('Text')); } } @@ -266,6 +266,7 @@ FileUpload.propTypes = { getFileCount: React.PropTypes.func, onFileUpload: React.PropTypes.func, onUploadStart: React.PropTypes.func, + onTextDrop: React.PropTypes.func, channelId: React.PropTypes.string, postType: React.PropTypes.string }; |