From 51e17d2ce9368c3546b7e27809dfbd187cefb246 Mon Sep 17 00:00:00 2001 From: jmoenig Date: Wed, 30 Apr 2014 12:18:06 +0200 Subject: enable storage of first-class costumes --- history.txt | 6 ++++++ objects.js | 2 +- store.js | 14 ++++++++++---- 3 files changed, 17 insertions(+), 5 deletions(-) diff --git a/history.txt b/history.txt index 2c0362b..69b48bc 100755 --- a/history.txt +++ b/history.txt @@ -2109,3 +2109,9 @@ ______ * Objects: experimental “wardrobe” and “jukebox” reporters in dev mode * Blocks, Objects: display costume thumbnails in speech/thought/value bubbles and watcher cells * Objects: let “switch to costume” block accept actual costume objects (in addition to names and numbers) + +140430 +------ +* new Finnish translation, yay! Thanks, Jouni! +* new Brazilian Portuguese translation, yay! Thanks, Aldo! +* enable storage and retrieval of first-class costumes in both file formats diff --git a/objects.js b/objects.js index 1c4e61e..b506195 100644 --- a/objects.js +++ b/objects.js @@ -124,7 +124,7 @@ PrototypeHatBlockMorph*/ // Global stuff //////////////////////////////////////////////////////// -modules.objects = '2014-March-31'; +modules.objects = '2014-April-30'; var SpriteMorph; var StageMorph; diff --git a/store.js b/store.js index b3f5d95..d69667a 100644 --- a/store.js +++ b/store.js @@ -61,7 +61,7 @@ SyntaxElementMorph*/ // Global stuff //////////////////////////////////////////////////////// -modules.store = '2014-February-13'; +modules.store = '2014-April-30'; // XML_Serializer /////////////////////////////////////////////////////// @@ -457,8 +457,6 @@ SnapSerializer.prototype.loadProjectModel = function (xmlNode) { } }); - this.objects = {}; - /* Global Variables */ if (model.globalVariables) { @@ -468,6 +466,8 @@ SnapSerializer.prototype.loadProjectModel = function (xmlNode) { ); } + this.objects = {}; + /* Watchers */ model.sprites.childrenNamed('watcher').forEach(function (model) { @@ -521,7 +521,7 @@ SnapSerializer.prototype.loadProjectModel = function (xmlNode) { )) ); project.stage.add(watcher); - watcher.update(); + watcher.onNextStep = function () {this.currentValue = null; }; // set watcher's contentsMorph's extent if it is showing a list and // its monitor dimensions are given @@ -1302,6 +1302,12 @@ SnapSerializer.prototype.openProject = function (project, ide) { ide.createCorral(); ide.selectSprite(sprite); ide.fixLayout(); + + // force watchers to update + //project.stage.watchers().forEach(function (watcher) { + // watcher.onNextStep = function () {this.currentValue = null;}; + //}) + ide.world().keyboardReceiver = project.stage; }; -- cgit v1.3.1