diff options
| author | Gubolin <gubolin@fantasymail.de> | 2015-03-20 20:18:12 +0100 |
|---|---|---|
| committer | Gubolin <gubolin@fantasymail.de> | 2015-03-20 20:18:12 +0100 |
| commit | c8de6a00e38e52bfc4b9b3a095cbcad1861687de (patch) | |
| tree | 60a7563a44281ed8aedabffc0f617e82fa54bee9 | |
| parent | b6d846444e44d41842e253b7276cd590d7163349 (diff) | |
| parent | fdd2ecf7d91d8026d3ca42c4bd52774877c72645 (diff) | |
| download | snap-c8de6a00e38e52bfc4b9b3a095cbcad1861687de.tar.gz snap-c8de6a00e38e52bfc4b9b3a095cbcad1861687de.zip | |
Merge branch 'master' into development
| -rw-r--r-- | blocks.js | 24 | ||||
| -rw-r--r-- | gui.js | 10 | ||||
| -rwxr-xr-x | history.txt | 10 | ||||
| -rwxr-xr-x | snap.html | 2 | ||||
| -rw-r--r-- | store.js | 4 |
5 files changed, 30 insertions, 20 deletions
@@ -155,7 +155,7 @@ DialogBoxMorph, BlockInputFragmentMorph, PrototypeHatBlockMorph, Costume*/ // Global stuff //////////////////////////////////////////////////////// -modules.blocks = '2015-March-06'; +modules.blocks = '2015-March-09'; var SyntaxElementMorph; @@ -340,7 +340,7 @@ SyntaxElementMorph.prototype.setScale = function (num) { }; SyntaxElementMorph.prototype.setScale(1); -SyntaxElementMorph.prototype.isCachingInputs = true; +SyntaxElementMorph.prototype.isCachingInputs = false; // SyntaxElementMorph instance creation: @@ -400,10 +400,14 @@ SyntaxElementMorph.prototype.debugCachedInputs = function () { } for (i = 0; i < realInputs.length; i += 1) { if (this.cachedInputs[i] !== realInputs[i]) { - throw new Error('cached input does not match ' + + throw new Error('cached input does not match: ' + this.constructor.name + + ' #' + + i + ' ' + - i); + this.cachedInputs[i].constructor.name + + ' != ' + + realInputs[i].constructor.name); } } }; @@ -1960,6 +1964,7 @@ BlockMorph.uber = SyntaxElementMorph.prototype; // BlockMorph preferences settings: +BlockMorph.prototype.isCachingInputs = true; BlockMorph.prototype.zebraContrast = 40; // alternating color brightness // BlockMorph sound feedback: @@ -3080,6 +3085,9 @@ BlockMorph.prototype.fullCopy = function () { ans.setSpec(this.instantiationSpec); } ans.allChildren().filter(function (block) { + if (block instanceof SyntaxElementMorph) { + block.cachedInputs = null; + } return !isNil(block.comment); }).forEach(function (block) { var cmnt = block.comment.fullCopy(); @@ -9276,10 +9284,6 @@ MultiArgMorph.prototype = new ArgMorph(); MultiArgMorph.prototype.constructor = MultiArgMorph; MultiArgMorph.uber = ArgMorph.prototype; -// MultiArgMorph preferences settings - -MultiArgMorph.prototype.isCachingInputs = false; - // MultiArgMorph instance creation: function MultiArgMorph( @@ -9710,10 +9714,6 @@ ArgLabelMorph.prototype = new ArgMorph(); ArgLabelMorph.prototype.constructor = ArgLabelMorph; ArgLabelMorph.uber = ArgMorph.prototype; -// ArgLabelMorph preferences settings - -ArgLabelMorph.prototype.isCachingInputs = false; - // MultiArgMorph instance creation: function ArgLabelMorph(argMorph, labelTxt) { @@ -69,7 +69,7 @@ SpeechBubbleMorph*/ // Global stuff //////////////////////////////////////////////////////// -modules.gui = '2015-February-28'; +modules.gui = '2015-March-15'; // Declarations @@ -2379,10 +2379,10 @@ IDE_Morph.prototype.settingsMenu = function () { addPreference( 'Cache Inputs', function () { - SyntaxElementMorph.prototype.isCachingInputs = - !SyntaxElementMorph.prototype.isCachingInputs; + BlockMorph.prototype.isCachingInputs = + !BlockMorph.prototype.isCachingInputs; }, - SyntaxElementMorph.prototype.isCachingInputs, + BlockMorph.prototype.isCachingInputs, 'uncheck to stop caching\ninputs (for debugging the evaluator)', 'check to cache inputs\nboosts recursion', true @@ -2711,7 +2711,7 @@ IDE_Morph.prototype.aboutSnap = function () { module, btn1, btn2, btn3, btn4, licenseBtn, translatorsBtn, world = this.world(); - aboutTxt = 'Snap! 4.0\nBuild Your Own Blocks\n\n--- beta ---\n\n' + aboutTxt = 'Snap! 4.0\nBuild Your Own Blocks\n\n--- rc ---\n\n' + 'Copyright \u24B8 2015 Jens M\u00F6nig and ' + 'Brian Harvey\n' + 'jens@moenig.org, bh@cs.berkeley.edu\n\n' diff --git a/history.txt b/history.txt index d042af4..b53e59c 100755 --- a/history.txt +++ b/history.txt @@ -2466,3 +2466,13 @@ ______ 150306 ------ * Blocks: fixed #736 + +150309 +------ +* Blocks: fixed #738 +* GUI, Blocks: Only enable input caching for blocks + +150315 +------ +* Store: fixed #743 +* GUI, html: switch from beta to release candidate @@ -2,7 +2,7 @@ <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> - <title>Snap! Build Your Own Blocks. Beta</title> + <title>Snap! Build Your Own Blocks</title> <link rel="shortcut icon" href="favicon.ico"> <script type="text/javascript" src="morphic.js"></script> <script type="text/javascript" src="widgets.js"></script> @@ -61,7 +61,7 @@ SyntaxElementMorph, Variable*/ // Global stuff //////////////////////////////////////////////////////// -modules.store = '2015-February-28'; +modules.store = '2015-March-15'; // XML_Serializer /////////////////////////////////////////////////////// @@ -782,7 +782,7 @@ SnapSerializer.prototype.loadCustomBlocks = function ( names = definition.parseSpec(definition.spec).filter( function (str) { - return str.charAt(0) === '%'; + return str.charAt(0) === '%' && str.length > 1; } ).map(function (str) { return str.substr(1); |
