Commit fd7e5f68 authored by Evan W. Patton's avatar Evan W. Patton Committed by Jeffrey Schiller

Update Closure Library to fix typeblocking autocomplete

Change-Id: Ia732cb6a35725ef49bb5605f1ab0bc6a808fe33b
parent 8ebc19f0
......@@ -3,4 +3,4 @@
url = https://github.com/mit-cml/blockly.git
[submodule "appinventor/lib/closure-library"]
path = appinventor/lib/closure-library
url = https://github.com/google/closure-library.git
url = https://github.com/mit-cml/closure-library.git
......@@ -170,6 +170,10 @@ Blockly.TypeBlock.prototype.handleKey = function(e){
case 34: // Page Down
case 35: // Shift
case 36: // End
case 37: // Left Arrow
case 38: // Up Arrow
case 39: // Right Arrow
case 40: // Down Arrow
case 45: // Ins
case 91: // Meta
case 112: // F1
......@@ -197,8 +201,12 @@ Blockly.TypeBlock.prototype.handleKey = function(e){
// Can't seem to make Firefox display first character, so keep all browsers from automatically
// displaying the first character and add it manually.
e.preventDefault();
if (e.charCode == 0) {
// Don't try to render a non-printing character.
return;
}
goog.dom.getElement(this.inputText_).value =
String.fromCharCode(e.charCode != null ? e.charCode : e.keycode);
String.fromCharCode(e.charCode != null ? e.charCode : e.keyCode);
}
};
......
Subproject commit effb4062e34576a011e788a0d33c1433a677f940
Subproject commit 91eccc0185c296aa9eda3e025cf186469895e84b
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment