From c2087e61f5892caee236dd4bae0da3d50d7d655f Mon Sep 17 00:00:00 2001 From: Monica Kozbial Date: Fri, 10 Jan 2020 13:32:44 -0800 Subject: [PATCH] Using shapeFor to determine connections shape for marker_svg. (#3573) --- core/renderers/common/marker_svg.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/core/renderers/common/marker_svg.js b/core/renderers/common/marker_svg.js index 8fbe618a5..f845922cc 100644 --- a/core/renderers/common/marker_svg.js +++ b/core/renderers/common/marker_svg.js @@ -235,7 +235,7 @@ Blockly.blockRendering.MarkerSvg.prototype.showWithField_ = function(curNode) { * @protected */ Blockly.blockRendering.MarkerSvg.prototype.showWithInput_ = function(curNode) { - var connection = /** @type {Blockly.Connection} */ + var connection = /** @type {Blockly.RenderedConnection} */ (curNode.getLocation()); var sourceBlock = /** @type {!Blockly.BlockSvg} */ (connection.getSourceBlock()); @@ -333,7 +333,7 @@ Blockly.blockRendering.MarkerSvg.prototype.positionBlock_ = function( /** * Position the marker for an input connection. * Displays a filled in puzzle piece. - * @param {!Blockly.Connection} connection The connection to position marker around. + * @param {!Blockly.RenderedConnection} connection The connection to position marker around. * @private */ Blockly.blockRendering.MarkerSvg.prototype.positionInput_ = function(connection) { @@ -341,7 +341,7 @@ Blockly.blockRendering.MarkerSvg.prototype.positionInput_ = function(connection) var y = connection.getOffsetInBlock().y; var path = Blockly.utils.svgPaths.moveTo(0, 0) + - this.constants_.PUZZLE_TAB.pathDown; + this.constants_.shapeFor(connection).pathDown; this.markerInput_.setAttribute('d', path); this.markerInput_.setAttribute('transform',