From 6d4b91f89fcb54066c9daddcc9ea92f81996a4c9 Mon Sep 17 00:00:00 2001 From: nightwing Date: Tue, 30 Apr 2013 13:29:29 +0400 Subject: [PATCH] linux ime --- lib/ace/keyboard/textinput.js | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/lib/ace/keyboard/textinput.js b/lib/ace/keyboard/textinput.js index e23fa565..e7fbab5b 100644 --- a/lib/ace/keyboard/textinput.js +++ b/lib/ace/keyboard/textinput.js @@ -387,7 +387,7 @@ var TextInput = function(parentNode, host) { inComposition = false; var timer = setTimeout(function() { var str = text.value.replace(/\x01/g, ""); - console.log(str, c.lastValue) + // console.log(str, c.lastValue) if (inComposition) return else if (str == c.lastValue) @@ -403,10 +403,8 @@ var TextInput = function(parentNode, host) { str = str.replace(/\x01/g, ""); if (str == c.lastValue) return ""; - if (str) { - if (c.lastValue) - host.undo(); - } + if (c.lastValue) + host.undo(); return str; } host.onCompositionEnd();