Properly deal with shadow statement blocks in stacks.

This commit is contained in:
Neil Fraser
2016-06-05 16:58:27 -07:00
parent f642fa80d5
commit 9ca00656ad
2 changed files with 4 additions and 3 deletions

View File

@@ -180,8 +180,9 @@ Blockly.Connection.prototype.connect_ = function(childConnection) {
// block. Since this block may be a stack, walk down to the end.
var newBlock = childBlock;
while (newBlock.nextConnection) {
if (newBlock.nextConnection.isConnected()) {
newBlock = newBlock.getNextBlock();
var nextBlock = newBlock.getNextBlock();
if (nextBlock && !nextBlock.isShadow()) {
newBlock = nextBlock;
} else {
if (orphanBlock.previousConnection.checkType_(
newBlock.nextConnection)) {

View File

@@ -161,7 +161,7 @@ h1 {
</xml>
<xml id="toolbox-categories" style="display: none">
<category name="Logic" colour="210">
<category name="Logic" colour="210">
<block type="controls_if"></block>
<block type="logic_compare"></block>
<block type="logic_operation"></block>