diff --git a/HISTORY.md b/HISTORY.md index 8df2098a..73380e48 100755 --- a/HISTORY.md +++ b/HISTORY.md @@ -12,11 +12,15 @@ * changing the type of a custom block from reporter to command in the block editor changes the prototype instead of adding another one * deleting project notes in the "save" dialog now also deletes them in the saved project * items in list-boxes such as the project list are no longer auto-translated + * fixed a redo issue * **Translation Updates:** * Catalan, thanks, Joan! * Norwegian, thanks, Olav! * German +### 2020-09-14 +* blocks: fixed "redrop" (redo) + ### 2020-09-12 * morphic: don't auto-translate ListMorph items diff --git a/snap.html b/snap.html index ca74d36f..cc2e1535 100755 --- a/snap.html +++ b/snap.html @@ -8,7 +8,7 @@ - + diff --git a/src/blocks.js b/src/blocks.js index ce15bb8b..35a2009c 100644 --- a/src/blocks.js +++ b/src/blocks.js @@ -158,7 +158,7 @@ CustomCommandBlockMorph, SymbolMorph, ToggleButtonMorph, DialMorph*/ // Global stuff //////////////////////////////////////////////////////// -modules.blocks = '2020-September-04'; +modules.blocks = '2020-September-14'; var SyntaxElementMorph; var BlockMorph; @@ -7373,10 +7373,17 @@ ScriptsMorph.prototype.recoverLastDrop = function (forRedrop) { } } else if (dropped instanceof ReporterBlockMorph) { if (rec.lastDropTarget) { - rec.lastDropTarget.replaceInput( - rec.lastDroppedBlock, - rec.lastReplacedInput - ); + if (forRedrop) { + rec.lastDropTarget.replaceInput( + rec.lastReplacedInput, + rec.lastDroppedBlock + ); + } else { + rec.lastDropTarget.replaceInput( + rec.lastDroppedBlock, + rec.lastReplacedInput + ); + } rec.lastDropTarget.fixBlockColor(null, true); if (rec.lastPreservedBlocks) { rec.lastPreservedBlocks.forEach(morph =>