From 2bcb381aa73201b3c5d1e0bb8ab9cf04816535c6 Mon Sep 17 00:00:00 2001 From: Michael Telatynski <7t3chguy@gmail.com> Date: Sat, 27 May 2017 14:19:34 +0100 Subject: [PATCH] maybe window focus should be ignored so focus is left as what it was but with this at least clicking on a text input will not make you be thrown into composer instead Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> --- src/components/structures/MatrixChat.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/components/structures/MatrixChat.js b/src/components/structures/MatrixChat.js index 0de38ab226..a4b6b3ea6c 100644 --- a/src/components/structures/MatrixChat.js +++ b/src/components/structures/MatrixChat.js @@ -906,7 +906,9 @@ module.exports = React.createClass({ }, onFocus: function(ev) { - dis.dispatch({action: 'focus_composer'}); + if (document.activeElement.textLength === undefined) { + dis.dispatch({action: 'focus_composer'}); + } }, showScreen: function(screen, params) {