Merge pull request #478 from sharelatex/pr-fix-safari-accent-handling

Fix safari accent handling
This commit is contained in:
James Allen 2017-04-05 11:08:24 +01:00 committed by GitHub
commit 6e7b2aaacb

View file

@ -2283,9 +2283,13 @@ var TextInput = function(parentNode, host) {
if (e.type == "compositionend" && c.range) {
host.selection.setRange(c.range);
}
// WORKAROUND: Accent keys and Korean keys don't work in Chrome >53.
// https://github.com/ajaxorg/ace/issues/3045
if (useragent.isChrome >= 53) onInput();
var needsOnInput =
(!!useragent.isChrome && useragent.isChrome >= 53) ||
(!!useragent.isWebKit && useragent.isWebKit >= 603);
if (needsOnInput) {
onInput();
}
};