Skip to content

Commit

Permalink
Merge pull request #2168 from alschmiedt/procedure_events
Browse files Browse the repository at this point in the history
Groups events fired during field input change
  • Loading branch information
alschmiedt committed Dec 13, 2018
2 parents 0c66429 + 4bd21c5 commit 91cc05a
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions core/field_textinput.js
Expand Up @@ -281,7 +281,13 @@ Blockly.FieldTextInput.prototype.onHtmlInputChange_ = function(_e) {
var text = htmlInput.value;
if (text !== htmlInput.oldValue_) {
htmlInput.oldValue_ = text;

// TODO(#2169): Once issue is fixed the setGroup functionality could be
// moved up to the Field setValue method. This would create a
// broader fix for all field types.
Blockly.Events.setGroup(true);
this.setValue(text);
Blockly.Events.setGroup(false);
this.validate_();
} else if (goog.userAgent.WEBKIT) {
// Cursor key. Render the source block to show the caret moving.
Expand Down

0 comments on commit 91cc05a

Please sign in to comment.