From 3a9e258fef2cf030b4357013319208d77f7e430e Mon Sep 17 00:00:00 2001 From: jmoenig Date: Fri, 22 Nov 2013 11:57:37 +0100 Subject: [PATCH] =?UTF-8?q?Prevent=20=E2=80=9Ehide=E2=80=9C=20menu=20optio?= =?UTF-8?q?n=20for=20non-palette=20template=20blocks?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit thanks, Brian, for reporting this glitch! --- blocks.js | 4 ++-- history.txt | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/blocks.js b/blocks.js index 3ab3fad5..c6f00bfd 100644 --- a/blocks.js +++ b/blocks.js @@ -155,7 +155,7 @@ DialogBoxMorph, BlockInputFragmentMorph, PrototypeHatBlockMorph, Costume*/ // Global stuff //////////////////////////////////////////////////////// -modules.blocks = '2013-November-15'; +modules.blocks = '2013-November-22'; var SyntaxElementMorph; var BlockMorph; @@ -1969,7 +1969,7 @@ BlockMorph.prototype.userMenu = function () { "help...", 'showHelp' ); - if (this.isTemplate) { + if (this.isTemplate && !(this.parent instanceof SyntaxElementMorph)) { if (this.selector !== 'evaluateCustomBlock') { menu.addItem( "hide", diff --git a/history.txt b/history.txt index 5228d501..49fa9e6c 100755 --- a/history.txt +++ b/history.txt @@ -2004,3 +2004,4 @@ ______ 131122 ------ * Morphic: Don’t trigger events for eclipsed morphs (whose parent-chain contains a hidden morph) +* Blocks: Prevent „hide“ menu option for non-palette template blocks