diff --git a/.vs/AAWeb/v15/.suo b/.vs/AAWeb/v15/.suo
index 353cf8240..4a684b9f4 100644
Binary files a/.vs/AAWeb/v15/.suo and b/.vs/AAWeb/v15/.suo differ
diff --git a/Project.njsproj b/Project.njsproj
index cc4dd052a..57dbdc3d1 100644
--- a/Project.njsproj
+++ b/Project.njsproj
@@ -69,7 +69,7 @@
-
+
@@ -83,7 +83,7 @@
-
+
diff --git a/ChartSpace.js b/Spaces/ChartSpace.js
similarity index 100%
rename from ChartSpace.js
rename to Spaces/ChartSpace.js
diff --git a/FloatingSpace.js b/Spaces/FloatingSpace.js
similarity index 100%
rename from FloatingSpace.js
rename to Spaces/FloatingSpace.js
diff --git a/Spaces/PanelsSpace.js b/Spaces/PanelsSpace.js
index 1117fd3cc..f2adebdd0 100644
--- a/Spaces/PanelsSpace.js
+++ b/Spaces/PanelsSpace.js
@@ -33,7 +33,7 @@ function newPanelsSpace() {
}
- function createNewPanel(pType) {
+ function createNewPanel(pType, pParameters) {
let panel;
@@ -52,6 +52,12 @@ function newPanelsSpace() {
panel.initialize();
break;
}
+ case "Plotter Panel":
+ {
+ panel = getNewPlotterPanel(pParameters.devTeam, pParameters.plotterCodeName, pParameters.moduleCodeName, pParameters.panelCodeName);
+ panel.initialize();
+ break;
+ }
}
thisObject.panels.push(panel);
diff --git a/TimelineChart.js b/TimelineChart.js
index d4784f133..784ce013a 100644
--- a/TimelineChart.js
+++ b/TimelineChart.js
@@ -231,21 +231,27 @@
for (let i = 0; i < pProductCard.product.plotter.module.panels.length; i++) {
- let panel = pProductCard.product.plotter.module.panels[i];
+ let panelConfig = pProductCard.product.plotter.module.panels[i];
- let plotterPanel = getNewPlotterPanel(pProductCard.product.plotter.devTeam, pProductCard.product.plotter.codeName, pProductCard.product.plotter.moduleName, panel.codeName);
+ let parameters = {
+ devTeam: pProductCard.product.plotter.devTeam,
+ plotterCodeName: pProductCard.product.plotter.codeName,
+ moduleCodeName: pProductCard.product.plotter.moduleName,
+ panelCodeName: panelConfig.codeName
+ }
- plotterPanel.initialize();
+ let plotterPanelHandle = canvas.panelsSpace.createNewPanel("Plotter Panel", parameters);
+ let plotterPanel = canvas.panelsSpace.getPanel(plotterPanelHandle);
/* Connect Panel to the Plotter via an Event. */
- if (panel.event !== undefined) {
+ if (panelConfig.event !== undefined) {
- productPlotter.plotter.container.eventHandler.listenToEvent(panel.event, plotterPanel.onEventRaised);
+ productPlotter.plotter.container.eventHandler.listenToEvent(panelConfig.event, plotterPanel.onEventRaised);
}
- productPlotter.panels.push(plotterPanel);
+ productPlotter.panels.push(plotterPanelHandle);
}
/* Create The Profie Picture Ball */
@@ -309,6 +315,14 @@
}
+ /* Finally the panels. */
+
+ for (let j = 0; j < productPlotters[i].panels.length; j++) {
+
+ canvas.panelsSpace.destroyPanel(productPlotters[i].panels[j]);
+
+ }
+
productPlotters.splice(i, 1); // Delete item from array.
}
@@ -431,25 +445,6 @@
if (this.container.frame.isThisPointHere(point) === true) {
- for (let i = 0; i < productPlotters.length; i++) {
-
- let productPlotter = productPlotters[i];
-
- for (let j = 0; j < productPlotter.panels.length; j++) {
-
- let panel = productPlotter.panels[j];
-
- let panelContainer = panel.getContainer(point);
-
- if (panelContainer !== undefined) {
-
- /* We found an inner container which has the point. We return it. */
-
- return panelContainer;
- }
- }
- }
-
// return this.container; Currently there is a BUG in which if this is enabled the datetime of the control panel is not recalculated.
} else {
@@ -522,20 +517,6 @@
let competitionPlotter = competitionPlotters[i];
competitionPlotter.plotter.draw();
}
-
- /* Finally the panels. */
-
- for (let i = 0; i < productPlotters.length; i++) {
-
- let productPlotter = productPlotters[i];
-
- for (let j = 0; j < productPlotter.panels.length; j++) {
-
- let panel = productPlotter.panels[j];
- panel.draw();
- }
- }
-
}
}
diff --git a/index.html b/index.html
index 2a3f76151..f89319c2e 100644
--- a/index.html
+++ b/index.html
@@ -31,8 +31,6 @@
-
-
@@ -70,6 +68,8 @@
+
+