mirror of
https://github.com/google/blockly.git
synced 2026-01-07 17:10:11 +01:00
Moves setCollapsed to after mutation (#3591)
This commit is contained in:
@@ -248,13 +248,13 @@ Blockly.InsertionMarkerManager.prototype.createMarkerBlock_ = function(sourceBlo
|
||||
try {
|
||||
var result = this.workspace_.newBlock(imType);
|
||||
result.setInsertionMarker(true);
|
||||
result.setCollapsed(sourceBlock.isCollapsed());
|
||||
if (sourceBlock.mutationToDom) {
|
||||
var oldMutationDom = sourceBlock.mutationToDom();
|
||||
if (oldMutationDom) {
|
||||
result.domToMutation(oldMutationDom);
|
||||
}
|
||||
}
|
||||
result.setCollapsed(sourceBlock.isCollapsed());
|
||||
// Copy field values from the other block. These values may impact the
|
||||
// rendered size of the insertion marker. Note that we do not care about
|
||||
// child blocks here.
|
||||
|
||||
Reference in New Issue
Block a user