diff --git a/.vs/AAWeb/v15/.suo b/.vs/AAWeb/v15/.suo index d69fdfb98..77d9f4853 100644 Binary files a/.vs/AAWeb/v15/.suo and b/.vs/AAWeb/v15/.suo differ diff --git a/Ball.js b/FloatingObject.js similarity index 99% rename from Ball.js rename to FloatingObject.js index c4081a7a4..e614a3259 100644 --- a/Ball.js +++ b/FloatingObject.js @@ -1,5 +1,5 @@  -function newBall() { +function newFloatingObject() { var thisObject = { diff --git a/Project.njsproj b/Project.njsproj index 1422d6f06..fb318ddd7 100644 --- a/Project.njsproj +++ b/Project.njsproj @@ -33,7 +33,7 @@ - + Code diff --git a/Spaces/FloatingSpace.js b/Spaces/FloatingSpace.js index 68170c126..2801cf899 100644 --- a/Spaces/FloatingSpace.js +++ b/Spaces/FloatingSpace.js @@ -9,13 +9,16 @@ function newFloatingSpace() { balls: undefined, // This is the array of balls being displayed createNewBall: createNewBall, destroyBall: destroyBall, + createBubbleSet: createBubbleSet, + destroyBubbleSet: destroyBubbleSet, physicsLoop: physicsLoop, isInside: isInside, isInsideBall: isInsideBall, initialize: initialize }; - let createdBalls = []; + let createdBalls = []; + let bubbleSets = []; return thisObject; @@ -28,9 +31,9 @@ function newFloatingSpace() { function createNewBall(pInput, pContainer) { - /* This function is used to create new balls, representing labels of each point on the chart. */ + /* This function is used to create new balls */ - var ball = newBall(); + var ball = newFloatingObject(); ball.input = pInput; @@ -75,6 +78,33 @@ function newFloatingSpace() { } } + + function createBubbleSet(pPlotterBubbles) { + + let bubbleSet = { + floatingBubbles: [], + plotterBubbles: pPlotterBubbles, + handle: Math.floor((Math.random() * 10000000) + 1) + }; + + bubbleSets.push(bubbleSet); + + return bubbleSet.handle; + } + + function destroyBubbleSet(pHandle) { + + for (let i = 0; i < bubbleSets.length; i++) { + + let bubbleSet = bubbleSets[i]; + + if (bubbleSet.handle === pHandle) { + bubbleSets.splice(i, 1); // Delete item from array. + return; + } + } + } + /******************************************/ /* */ /* Physics Engine Follows */ diff --git a/TimelineChart.js b/TimelineChart.js index fd7c27c4c..f366b4afc 100644 --- a/TimelineChart.js +++ b/TimelineChart.js @@ -268,7 +268,8 @@ productCard: pProductCard, plotter: plotter, storage: storage, - profile: undefined + profile: undefined, + bubbles: undefined }; /* Let the Plotter listen to the event of Cursor Files loaded, so that it can reack recalculating if needed. */ @@ -318,6 +319,10 @@ } + /* Create the Text Bubbles */ + + productPlotter.bubbleSet = canvas.floatingSpace.createBubbleSet(productPlotter.plotter.bubbles); + /* Add the new Active Protter to the Array */ productPlotters.push(productPlotter); @@ -368,6 +373,10 @@ } + /* Destroyd the Bubble Set */ + + canvas.floatingSpace.destroyBubbleSet(productPlotters[i].bubbleSet); + /* Finally the panels. */ for (let j = 0; j < productPlotters[i].panels.length; j++) { diff --git a/index.html b/index.html index 1fee9aea2..6c02b864e 100644 --- a/index.html +++ b/index.html @@ -27,7 +27,7 @@ - + diff --git a/node_modules/atob/README.md b/node_modules/atob/README.md index b8cffda6a..e15ef86b0 100644 --- a/node_modules/atob/README.md +++ b/node_modules/atob/README.md @@ -1,6 +1,11 @@ atob === +| **atob** +| [btoa](https://git.coolaj86.com/coolaj86/btoa.js) +| [unibabel.js](https://git.coolaj86.com/coolaj86/unibabel.js) +| Sponsored by [ppl](https://ppl.family) + Uses `Buffer` to emulate the exact functionality of the browser's atob. Note: Unicode may be handled incorrectly (like the browser). @@ -12,32 +17,33 @@ It turns base64-encoded ascii data back **to** b= 0.4.0" + "node": ">= 4.5.0" }, - "homepage": "https://github.com/coolaj86/node-browser-compat", + "homepage": "https://git.coolaj86.com/coolaj86/atob.js.git", "keywords": [ "atob", "browser" @@ -48,7 +48,7 @@ "name": "atob", "repository": { "type": "git", - "url": "git://github.com/coolaj86/node-browser-compat/atob.git" + "url": "git://git.coolaj86.com/coolaj86/atob.js.git" }, - "version": "2.0.3" + "version": "2.1.1" } diff --git a/node_modules/atob/test.js b/node_modules/atob/test.js index e499dd574..bd80a4ea1 100644 --- a/node_modules/atob/test.js +++ b/node_modules/atob/test.js @@ -1,15 +1,13 @@ -/*jshint strict:true node:true es5:true onevar:true laxcomma:true laxbreak:true eqeqeq:true immed:true latedef:true*/ (function () { "use strict"; - var atob = require('.') - , encoded = "SGVsbG8gV29ybGQ=" - , unencoded = "Hello World" + var atob = require('.'); + var encoded = "SGVsbG8sIFdvcmxkIQ==" + var unencoded = "Hello, World!"; /* , encoded = "SGVsbG8sIBZM" , unencoded = "Hello, 世界" */ - ; if (unencoded !== atob(encoded)) { console.log('[FAIL]', unencoded, atob(encoded)); diff --git a/package-lock.json b/package-lock.json index 58212bc32..f30739d79 100644 --- a/package-lock.json +++ b/package-lock.json @@ -18,9 +18,9 @@ } }, "atob": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/atob/-/atob-2.0.3.tgz", - "integrity": "sha1-GcenYEc3dEaPILLS0DNyrX1Mv10=" + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/atob/-/atob-2.1.1.tgz", + "integrity": "sha1-ri1acpR38onWDdf5amMUoi3Wwio=" }, "before-after-hook": { "version": "1.1.0", diff --git a/package.json b/package.json index 3d86cfd48..8b9cd455a 100644 --- a/package.json +++ b/package.json @@ -8,7 +8,7 @@ }, "dependencies": { "@octokit/rest": "^14.0.9", - "atob": "^2.0.3", + "atob": "^2.1.1", "octokit": "^0.10.4" } } diff --git a/server.js b/server.js index 1cf8bb361..330817bd6 100644 --- a/server.js +++ b/server.js @@ -6,7 +6,7 @@ if (CONSOLE_LOG === true) { } -const DEBUG_MODE = false; // This forces the server to read Plotters from the local drive. +const DEBUG_MODE = true; // This forces the server to read Plotters from the local drive. if (CONSOLE_LOG === true && DEBUG_MODE === true) {