From de67108b17364d7a73689f85c2e7f11da7607dad Mon Sep 17 00:00:00 2001 From: Rachel Fenichel Date: Thu, 29 Jun 2017 15:13:56 -0700 Subject: [PATCH] Fix #1160 (#1197) Fix "Connection UI Effect not playing on block connect" --- core/block_svg.js | 2 +- core/dragged_connection_manager.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/core/block_svg.js b/core/block_svg.js index 6f44aed45..6c57850ea 100644 --- a/core/block_svg.js +++ b/core/block_svg.js @@ -912,7 +912,7 @@ Blockly.BlockSvg.disposeUiStep_ = function(clone, rtl, start, workspaceScale) { * Play some UI effects (sound, ripple) after a connection has been established. */ Blockly.BlockSvg.prototype.connectionUiEffect = function() { - this.workspace.getAudioManger().play('click'); + this.workspace.getAudioManager().play('click'); if (this.workspace.scale < 1) { return; // Too small to care about visual effects. } diff --git a/core/dragged_connection_manager.js b/core/dragged_connection_manager.js index 414278dfd..1ebe2ef66 100644 --- a/core/dragged_connection_manager.js +++ b/core/dragged_connection_manager.js @@ -133,7 +133,7 @@ Blockly.DraggedConnectionManager.prototype.applyConnections = function() { if (this.closestConnection_) { // Connect two blocks together. this.localConnection_.connect(this.closestConnection_); - if (this.rendered) { + if (this.topBlock_.rendered) { // Trigger a connection animation. // Determine which connection is inferior (lower in the source stack). var inferiorConnection = this.localConnection_.isSuperior() ?