From 712576a5b1cca1aa1f150ee34bbf07524c3b7dbd Mon Sep 17 00:00:00 2001 From: Neil Fraser Date: Fri, 28 Jun 2019 16:13:21 -0700 Subject: [PATCH] Fix IE not unhighlighting This is a rework of PR #2580. --- core/block_svg.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/core/block_svg.js b/core/block_svg.js index 6060039f9..f843a6828 100644 --- a/core/block_svg.js +++ b/core/block_svg.js @@ -639,7 +639,7 @@ Blockly.BlockSvg.prototype.showHelp_ = function() { * @returns {Array} Context menu options */ Blockly.BlockSvg.prototype.generateContextMenu = function() { - + if (this.workspace.options.readOnly || !this.contextMenu) { return; } @@ -740,7 +740,7 @@ Blockly.BlockSvg.prototype.generateContextMenu = function() { */ Blockly.BlockSvg.prototype.showContextMenu_ = function(e) { var menuOptions = this.generateContextMenu(); - + if (menuOptions && menuOptions.length) { Blockly.ContextMenu.show(e, menuOptions, this.RTL); Blockly.ContextMenu.currentBlock = this; @@ -1207,8 +1207,8 @@ Blockly.BlockSvg.prototype.setHighlighted = function(highlighted) { 'url(#' + this.workspace.options.embossFilterId + ')'); this.svgPathLight_.style.display = 'none'; } else { - this.svgPath_.removeAttribute('filter'); - delete this.svgPathLight_.style.display; + this.svgPath_.setAttribute('filter', 'none'); + this.svgPathLight_.style.display = 'inline'; } };