From f6d22ee4f0b7f4954cbad17986f06f9a5f096e72 Mon Sep 17 00:00:00 2001
From: Saturnino Abril <saturnino.abril@gmail.com>
Date: Thu, 23 Feb 2017 17:57:41 +0900
Subject: [PLT-5445] Mobile view: Set focus back to message box after uploading
 a file (#5360)

---
 webapp/components/file_upload.jsx | 7 +++++++
 1 file changed, 7 insertions(+)

(limited to 'webapp/components/file_upload.jsx')

diff --git a/webapp/components/file_upload.jsx b/webapp/components/file_upload.jsx
index a821fedab..5710f2365 100644
--- a/webapp/components/file_upload.jsx
+++ b/webapp/components/file_upload.jsx
@@ -126,6 +126,8 @@ class FileUpload extends React.Component {
 
             Utils.clearFileInput(e.target);
         }
+
+        this.props.onFileUploadChange();
     }
 
     handleDrop(e) {
@@ -190,6 +192,8 @@ class FileUpload extends React.Component {
                 self.handleDrop(e);
             }
         });
+
+        this.props.onFileUploadChange();
     }
 
     componentWillUnmount() {
@@ -289,6 +293,8 @@ class FileUpload extends React.Component {
                 this.props.onUploadStart([clientId], channelId);
             }
         }
+
+        this.props.onFileUploadChange();
     }
 
     keyUpload(e) {
@@ -369,6 +375,7 @@ FileUpload.propTypes = {
     onClick: React.PropTypes.func,
     onFileUpload: React.PropTypes.func,
     onUploadStart: React.PropTypes.func,
+    onFileUploadChange: React.PropTypes.func,
     onTextDrop: React.PropTypes.func,
     channelId: React.PropTypes.string,
     postType: React.PropTypes.string
-- 
cgit v1.2.3-1-g7c22

