From 749f4478ab174711cdde95d32384c45cb2a203f1 Mon Sep 17 00:00:00 2001 From: ericrius1 Date: Tue, 23 Feb 2016 09:33:37 -0800 Subject: [PATCH] Fixed bug with parsing numbers for editjs --- examples/html/entityProperties.html | 2 +- examples/particle_explorer/particleExplorerTool.js | 2 -- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/examples/html/entityProperties.html b/examples/html/entityProperties.html index 67ed261b5d..e3ad77870d 100644 --- a/examples/html/entityProperties.html +++ b/examples/html/entityProperties.html @@ -75,7 +75,7 @@ function createEmitNumberPropertyUpdateFunction(propertyName) { return function() { EventBridge.emitWebEvent( - '{ "type":"update", "properties":{"' + propertyName + '":' + Number(this.value.toFixed(4)) + '}}' + '{ "type":"update", "properties":{"' + propertyName + '":' + parseFloat(this.value).toFixed(4) + '}}' ); }; } diff --git a/examples/particle_explorer/particleExplorerTool.js b/examples/particle_explorer/particleExplorerTool.js index 20dfa6f1ba..007eb717ec 100644 --- a/examples/particle_explorer/particleExplorerTool.js +++ b/examples/particle_explorer/particleExplorerTool.js @@ -32,11 +32,9 @@ ParticleExplorerTool = function() { that.destroyWebView = function() { if (!that.webView) { - print("EBL CAN'ZT CLOSE WEB VIEW- IT DOESNT EXISTS!") return; } - print("EBL CLOSING WEB VIEW") that.webView.close(); that.webView = null; that.activeParticleEntity = 0;