Copying values to insertion marker fields directly. (#3063)

This commit is contained in:
Monica Kozbial
2019-09-20 15:35:46 -07:00
committed by GitHub
parent 9318c370f9
commit 5609cda70f

View File

@@ -273,10 +273,12 @@ Blockly.InsertionMarkerManager.prototype.createMarkerBlock_ = function(sourceBlo
// rendered size of the insertion marker. Note that we do not care about
// child blocks here.
for (var i = 0; i < sourceBlock.inputList.length; i++) {
var input = sourceBlock.inputList[i];
for (var j = 0; j < input.fieldRow.length; j++) {
var field = input.fieldRow[j];
result.setFieldValue(field.getValue(), field.name);
var sourceInput = sourceBlock.inputList[i];
var resultInput = result.inputList[i];
for (var j = 0; j < sourceInput.fieldRow.length; j++) {
var sourceField = sourceInput.fieldRow[j];
var resultField = resultInput.fieldRow[j];
resultField.setValue(sourceField.getValue());
}
}