summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjmoenig <jens@moenig.org>2013-04-26 10:39:20 +0200
committerjmoenig <jens@moenig.org>2013-04-26 10:39:20 +0200
commit512d9d7ccef97ee63f072fdd226e3868becd5f2d (patch)
tree47c2009b41b8179b0db5965c073f5bde055cd187
parentba8569954c9a20413593c13b130379cb4ef033b6 (diff)
downloadsnap-yow-512d9d7ccef97ee63f072fdd226e3868becd5f2d.tar.gz
snap-yow-512d9d7ccef97ee63f072fdd226e3868becd5f2d.zip
Ensure unique World stamps
-rwxr-xr-xhistory.txt4
-rw-r--r--morphic.js5
2 files changed, 8 insertions, 1 deletions
diff --git a/history.txt b/history.txt
index 53d23e7..7c9c3c0 100755
--- a/history.txt
+++ b/history.txt
@@ -1670,3 +1670,7 @@ ______
* Morphic: Introducing World.stamp as reference in multi-World setups
* Widgets: restore multi-dialog restrictions for multi-world setups
* Translation update for "hide primitives" feature
+
+130426
+------
+* Morphic: ensure unique World stamps
diff --git a/morphic.js b/morphic.js
index 76af43f..e2779e5 100644
--- a/morphic.js
+++ b/morphic.js
@@ -1035,7 +1035,7 @@
/*global window, HTMLCanvasElement, getMinimumFontHeight, FileReader, Audio,
FileList, getBlurredShadowSupport*/
-var morphicVersion = '2013-April-25';
+var morphicVersion = '2013-April-26';
var modules = {}; // keep track of additional loaded modules
var useBlurredShadows = getBlurredShadowSupport(); // check for Chrome-bug
@@ -9886,6 +9886,9 @@ WorldMorph.prototype.init = function (aCanvas, fillPage) {
// additional properties:
this.stamp = Date.now(); // reference in multi-world setups
+ while (this.stamp === Date.now()) {nop(); }
+ this.stamp = Date.now();
+
this.useFillPage = fillPage;
if (this.useFillPage === undefined) {
this.useFillPage = true;