From d8e4d6170a0dddfca0cb319b2971a5a758d32e54 Mon Sep 17 00:00:00 2001 From: Luis Fernando Molina Date: Thu, 25 Oct 2018 12:17:26 +0200 Subject: [PATCH] Link to modules eliminated --- BottomSpace/KeyVaultModule.js | 141 ------------------------------ BottomSpace/TeamsModule.js | 141 ------------------------------ BottomSpace/UsersModule.js | 141 ------------------------------ Images/Icons/key-vault-module.png | Bin 466 -> 0 bytes Images/Icons/teams-module.png | Bin 560 -> 0 bytes Images/Icons/users-module.png | Bin 464 -> 0 bytes Project.njsproj | 9 -- Scripts/AppLoader.js | 3 - Spaces/BottomSpace.js | 24 ----- 9 files changed, 459 deletions(-) delete mode 100644 BottomSpace/KeyVaultModule.js delete mode 100644 BottomSpace/TeamsModule.js delete mode 100644 BottomSpace/UsersModule.js delete mode 100644 Images/Icons/key-vault-module.png delete mode 100644 Images/Icons/teams-module.png delete mode 100644 Images/Icons/users-module.png diff --git a/BottomSpace/KeyVaultModule.js b/BottomSpace/KeyVaultModule.js deleted file mode 100644 index 5e4123817..000000000 --- a/BottomSpace/KeyVaultModule.js +++ /dev/null @@ -1,141 +0,0 @@ - -function newKeyVaultModule() { - - const MODULE_NAME = "Key Vault Module Button"; - const INFO_LOG = false; - const ERROR_LOG = true; - const logger = newWebDebugLog(); - logger.fileName = MODULE_NAME; - - var thisObject = { - container: undefined, - draw: draw, - getContainer: getContainer, // returns the inner most container that holds the point received by parameter. - initialize: initialize - }; - - var container = newContainer(); - container.initialize(); - thisObject.container = container; - - thisObject.container.frame.width = 50; - thisObject.container.frame.height = BOTTOM_SPACE_HEIGHT; - - container.frame.position.x = viewPort.visibleArea.topLeft.x + thisObject.container.frame.width * 2; - container.frame.position.y = viewPort.visibleArea.bottomLeft.y; - - container.isDraggeable = false; - container.isClickeable = true; - - let icon; - let canDrawIcon = false; - - return thisObject; - - function initialize(callBackFunction) { - - try { - - if (INFO_LOG === true) { logger.write("[INFO] initialize -> Entering function."); } - - if (window.canvasApp.executingAt === 'Master App') { - return; - } - - icon = new Image(); - - icon.onload = onImageLoad; - - function onImageLoad() { - canDrawIcon = true; - } - - icon.src = window.canvasApp.urlPrefix + "Images/Icons/key-vault-module.png"; - - thisObject.container.eventHandler.listenToEvent("onMouseClick", onClick); - - if (callBackFunction !== undefined) { callBackFunction(GLOBAL.DEFAULT_OK_RESPONSE); } - - } catch (err) { - - if (ERROR_LOG === true) { logger.write("[ERROR] initialize -> err.message = " + err.message); } - if (callBackFunction !== undefined) { callBackFunction(GLOBAL.DEFAULT_FAIL_RESPONSE); } - } - } - - function onClick() { - - try { - - if (INFO_LOG === true) { logger.write("[INFO] onClick -> Entering function."); } - - window.open('https://keyVault.advancedalgos.net', '_blank'); - - - } catch (err) { - - if (ERROR_LOG === true) { logger.write("[ERROR] onClick -> err.message = " + err.message); } - - } - } - - function getContainer(point) { - - try { - - if (INFO_LOG === true) { logger.write("[INFO] getContainer -> Entering function."); } - - let container; - - /* First we check if this point is inside this object UI. */ - - if (thisObject.container.frame.isThisPointHere(point, true) === true) { - - return this.container; - - } else { - - /* This point does not belong to this space. */ - - return undefined; - } - - } catch (err) { - - if (ERROR_LOG === true) { logger.write("[ERROR] getContainer -> err.message = " + err.message); } - - } - } - - function draw() { - - try { - - if (INFO_LOG === true) { logger.write("[INFO] draw -> Entering function."); } - - thisObject.container.frame.draw(false, false); - - if (canDrawIcon === false) { return; } - - let breakpointsHeight = 15; - - let imageHeight = 15; - let imageWidth = 15; - - let imagePoint = { - x: 10, - y: thisObject.container.frame.height / 2 - imageHeight / 2 + breakpointsHeight - }; - - imagePoint = thisObject.container.frame.frameThisPoint(imagePoint); - - browserCanvasContext.drawImage(icon, imagePoint.x, imagePoint.y, imageWidth, imageHeight); - - - } catch (err) { - - if (ERROR_LOG === true) { logger.write("[ERROR] draw -> err.message = " + err.message); } - - } - } -} \ No newline at end of file diff --git a/BottomSpace/TeamsModule.js b/BottomSpace/TeamsModule.js deleted file mode 100644 index a22479bd6..000000000 --- a/BottomSpace/TeamsModule.js +++ /dev/null @@ -1,141 +0,0 @@ - -function newTeamsModule() { - - const MODULE_NAME = "Teams Module Button"; - const INFO_LOG = false; - const ERROR_LOG = true; - const logger = newWebDebugLog(); - logger.fileName = MODULE_NAME; - - var thisObject = { - container: undefined, - draw: draw, - getContainer: getContainer, // returns the inner most container that holds the point received by parameter. - initialize: initialize - }; - - var container = newContainer(); - container.initialize(); - thisObject.container = container; - - thisObject.container.frame.width = 50; - thisObject.container.frame.height = BOTTOM_SPACE_HEIGHT; - - container.frame.position.x = viewPort.visibleArea.topLeft.x + thisObject.container.frame.width * 1; - container.frame.position.y = viewPort.visibleArea.bottomLeft.y; - - container.isDraggeable = false; - container.isClickeable = true; - - let icon; - let canDrawIcon = false; - - return thisObject; - - function initialize(callBackFunction) { - - try { - - if (INFO_LOG === true) { logger.write("[INFO] initialize -> Entering function."); } - - if (window.canvasApp.executingAt === 'Master App') { - return; - } - - icon = new Image(); - - icon.onload = onImageLoad; - - function onImageLoad() { - canDrawIcon = true; - } - - icon.src = window.canvasApp.urlPrefix + "Images/Icons/teams-module.png"; - - thisObject.container.eventHandler.listenToEvent("onMouseClick", onClick); - - if (callBackFunction !== undefined) { callBackFunction(GLOBAL.DEFAULT_OK_RESPONSE); } - - } catch (err) { - - if (ERROR_LOG === true) { logger.write("[ERROR] initialize -> err.message = " + err.message); } - if (callBackFunction !== undefined) { callBackFunction(GLOBAL.DEFAULT_FAIL_RESPONSE); } - } - } - - function onClick() { - - try { - - if (INFO_LOG === true) { logger.write("[INFO] onClick -> Entering function."); } - - window.open('https://teams.advancedalgos.net', '_blank'); - - - } catch (err) { - - if (ERROR_LOG === true) { logger.write("[ERROR] onClick -> err.message = " + err.message); } - - } - } - - function getContainer(point) { - - try { - - if (INFO_LOG === true) { logger.write("[INFO] getContainer -> Entering function."); } - - let container; - - /* First we check if this point is inside this object UI. */ - - if (thisObject.container.frame.isThisPointHere(point, true) === true) { - - return this.container; - - } else { - - /* This point does not belong to this space. */ - - return undefined; - } - - } catch (err) { - - if (ERROR_LOG === true) { logger.write("[ERROR] getContainer -> err.message = " + err.message); } - - } - } - - function draw() { - - try { - - if (INFO_LOG === true) { logger.write("[INFO] draw -> Entering function."); } - - thisObject.container.frame.draw(false, false); - - if (canDrawIcon === false) { return; } - - let breakpointsHeight = 15; - - let imageHeight = 15; - let imageWidth = 15; - - let imagePoint = { - x: 10, - y: thisObject.container.frame.height / 2 - imageHeight / 2 + breakpointsHeight - }; - - imagePoint = thisObject.container.frame.frameThisPoint(imagePoint); - - browserCanvasContext.drawImage(icon, imagePoint.x, imagePoint.y, imageWidth, imageHeight); - - - } catch (err) { - - if (ERROR_LOG === true) { logger.write("[ERROR] draw -> err.message = " + err.message); } - - } - } -} \ No newline at end of file diff --git a/BottomSpace/UsersModule.js b/BottomSpace/UsersModule.js deleted file mode 100644 index 8682fa52d..000000000 --- a/BottomSpace/UsersModule.js +++ /dev/null @@ -1,141 +0,0 @@ - -function newUsersModule() { - - const MODULE_NAME = "Users Module Button"; - const INFO_LOG = false; - const ERROR_LOG = true; - const logger = newWebDebugLog(); - logger.fileName = MODULE_NAME; - - var thisObject = { - container: undefined, - draw: draw, - getContainer: getContainer, // returns the inner most container that holds the point received by parameter. - initialize: initialize - }; - - var container = newContainer(); - container.initialize(); - thisObject.container = container; - - thisObject.container.frame.width = 50; - thisObject.container.frame.height = BOTTOM_SPACE_HEIGHT; - - container.frame.position.x = viewPort.visibleArea.topLeft.x + thisObject.container.frame.width * 0; - container.frame.position.y = viewPort.visibleArea.bottomLeft.y; - - container.isDraggeable = false; - container.isClickeable = true; - - let icon; - let canDrawIcon = false; - - return thisObject; - - function initialize(callBackFunction) { - - try { - - if (INFO_LOG === true) { logger.write("[INFO] initialize -> Entering function."); } - - if (window.canvasApp.executingAt === 'Master App') { - return; - } - - icon = new Image(); - - icon.onload = onImageLoad; - - function onImageLoad() { - canDrawIcon = true; - } - - icon.src = window.canvasApp.urlPrefix + "Images/Icons/users-module.png"; - - thisObject.container.eventHandler.listenToEvent("onMouseClick", onClick); - - if (callBackFunction !== undefined) { callBackFunction(GLOBAL.DEFAULT_OK_RESPONSE); } - - } catch (err) { - - if (ERROR_LOG === true) { logger.write("[ERROR] initialize -> err.message = " + err.message); } - if (callBackFunction !== undefined) { callBackFunction(GLOBAL.DEFAULT_FAIL_RESPONSE); } - } - } - - function onClick() { - - try { - - if (INFO_LOG === true) { logger.write("[INFO] onClick -> Entering function."); } - - window.open('https://users.advancedalgos.net', '_blank'); - - - } catch (err) { - - if (ERROR_LOG === true) { logger.write("[ERROR] onClick -> err.message = " + err.message); } - - } - } - - function getContainer(point) { - - try { - - if (INFO_LOG === true) { logger.write("[INFO] getContainer -> Entering function."); } - - let container; - - /* First we check if this point is inside this object UI. */ - - if (thisObject.container.frame.isThisPointHere(point, true) === true) { - - return this.container; - - } else { - - /* This point does not belong to this space. */ - - return undefined; - } - - } catch (err) { - - if (ERROR_LOG === true) { logger.write("[ERROR] getContainer -> err.message = " + err.message); } - - } - } - - function draw() { - - try { - - if (INFO_LOG === true) { logger.write("[INFO] draw -> Entering function."); } - - thisObject.container.frame.draw(false, false); - - if (canDrawIcon === false) { return; } - - let breakpointsHeight = 15; - - let imageHeight = 15; - let imageWidth = 15; - - let imagePoint = { - x: 10, - y: thisObject.container.frame.height / 2 - imageHeight / 2 + breakpointsHeight - }; - - imagePoint = thisObject.container.frame.frameThisPoint(imagePoint); - - browserCanvasContext.drawImage(icon, imagePoint.x, imagePoint.y, imageWidth, imageHeight); - - - } catch (err) { - - if (ERROR_LOG === true) { logger.write("[ERROR] draw -> err.message = " + err.message); } - - } - } -} \ No newline at end of file diff --git a/Images/Icons/key-vault-module.png b/Images/Icons/key-vault-module.png deleted file mode 100644 index cafe26119a5c5fa5e5f929a6e16d2d5bd81944f6..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 466 zcmeAS@N?(olHy`uVBq!ia0vp^Dj>|k0wldT1B8JTQlTk>l^^1hPHm|D!ztRdU~R&xw`bIs zc+TVx*e=Su!gb3B=ANl#(W-Mb%#X5_g>Sl9Ipa{$dlTb5mCp~}X?)&!H6zz`j!;OG zQ0~QNvkdQdr2E}0QPAw{Q#+NlNI9`v8G^|jx$}@%e!Un z&M)hhX=T0gEn`iRz2QIe$4NOsgCz&Gt@Elw{I4orwCU#fzv*V2UmjEKl2>9^E5nvP z<=W+Y)zs}r$Op;5V#cG-Y(;h$or#c5`P-#D?_%Y_?8ed?{w34D@a)*!^q?uu&;7*0 z(iwR$>(dEXs}f|Gi=c@m$Q_Y}Cz-N(xGU}}6B=P&;Sl2?yUyR85G=1gEf zsg}4#l%ynmdKI;Vst07X!>mH+?% diff --git a/Images/Icons/teams-module.png b/Images/Icons/teams-module.png deleted file mode 100644 index 57c3b471804ec0d2d3a08bc9ed44b6d68dd2e24d..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 560 zcmeAS@N?(olHy`uVBq!ia0vp^Dj>|k0wldT1B8JTQhhz978;gznyC9eKzm;7a{Yq02A(Y$E!1xH80@`ES; zF^ZR#2Nx8G-HDOeqTwVP6XWXWEG{@ztb5B33zH0?{8=GQ7GL&Gm_4WXy>rodcO8*_ zA;ZF`1^Zc4ncrmkYUoB+-W2qlag0gzm6l=qBA&?`=WE?xW%MEXf?}NPj+)>#8-4Ok zE-dE%^5BNGMWIgWra%W*`4{&#=I_kWU$SSn&qMtm^YrIhzTQ-tZDfDR9027`Itodl%2`5{q~>lTJ1b5 zYi;b}SHWJUcVD?}ugcnYEoe=F%hA#$rbTD3MNRU(SF`fRxt_wi-#EL+;Z)RlzM$CIy<(_LPXWm zS@ELOI{)4(vxV9*U3-77m#$g9E_+3i_Qe0+n{yfuedY9jGfyf*d2%5z8dOVMBT7;d zOH!?pi&B9UgOP!ug|4B2u7PogfsvK5sg;qDu7RnQfx!~{*L)}%a`RI%(<*UmxSABa Q38;a=)78&qol`;+0Bi=|2mk;8 diff --git a/Images/Icons/users-module.png b/Images/Icons/users-module.png deleted file mode 100644 index af0f23b2780cae7b0f5740b73724a50797711b4b..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 464 zcmeAS@N?(olHy`uVBq!ia0vp^Dj>|k0wldT1B8JTQ3_3)7hJsLmaAjOZOUZ5xxoB(hQ)0kzjrl9=WM>dut;R;k)Op2B4U?1X@t5L zzSDWQ{#Z}wSqpyucEi3FU*5v93%qu*w;h%BGbCn}A9ULH^2FnPFK*15weeHpg&VK^ z-Y&3SU!DCv@JX-zrsZm{e6AS?XSs4|y7;t153aDUGBQtO zcowpGLA5d4g6X;6HlO2K@^8tn>kq|4zQh-*ihq)C{`Na#w;kh6!LkhBv>-=dFsYWf zMwFx^mZVxG7o`Fz1|tJQ3tdA4T?69~10yRFV=Gg0T?11q1A`mSSCpV=$jwj5OsmAL UVdXA?6F?0Np00i_>zopr0OB^ZTL1t6 diff --git a/Project.njsproj b/Project.njsproj index d7b57fc1d..d49d6508c 100644 --- a/Project.njsproj +++ b/Project.njsproj @@ -59,9 +59,6 @@ - - Code - @@ -72,9 +69,6 @@ - - Code - Code @@ -151,9 +145,6 @@ Code - - Code - Code diff --git a/Scripts/AppLoader.js b/Scripts/AppLoader.js index f1280025e..d5ee032fc 100644 --- a/Scripts/AppLoader.js +++ b/Scripts/AppLoader.js @@ -31,9 +31,6 @@ "BottomSpace/DeleteTradingHistory.js", "BottomSpace/ChartAspectRatio.js", - "BottomSpace/UsersModule.js", - "BottomSpace/TeamsModule.js", - "BottomSpace/KeyVaultModule.js", "BottomSpace/PlayStopButton.js", "TopSpace/CompanyLogo.js", diff --git a/Spaces/BottomSpace.js b/Spaces/BottomSpace.js index e2978ce52..b262752cd 100644 --- a/Spaces/BottomSpace.js +++ b/Spaces/BottomSpace.js @@ -4,9 +4,6 @@ function newBottomSpace() { var thisObject = { deleteTradingHistory: undefined, chartAspectRatio: undefined, - UsersModule: undefined, - TeamsModule: undefined, - KeyVaultModule: undefined, playStopButton: undefined, container: undefined, draw: draw, @@ -36,15 +33,6 @@ function newBottomSpace() { thisObject.chartAspectRatio = newChartAspectRatio(); thisObject.chartAspectRatio.initialize(); - thisObject.UsersModule = newUsersModule(); - thisObject.UsersModule.initialize(); - - thisObject.TeamsModule = newTeamsModule(); - thisObject.TeamsModule.initialize(); - - thisObject.KeyVaultModule = newKeyVaultModule(); - thisObject.KeyVaultModule.initialize(); - thisObject.playStopButton = newPlayStopButton(); thisObject.playStopButton.initialize(); } @@ -59,15 +47,6 @@ function newBottomSpace() { container = thisObject.chartAspectRatio.getContainer(point); if (container !== undefined) { return container; } - container = thisObject.UsersModule.getContainer(point); - if (container !== undefined) { return container; } - - container = thisObject.TeamsModule.getContainer(point); - if (container !== undefined) { return container; } - - container = thisObject.KeyVaultModule.getContainer(point); - if (container !== undefined) { return container; } - container = thisObject.playStopButton.getContainer(point); if (container !== undefined) { return container; } @@ -84,9 +63,6 @@ function newBottomSpace() { drawBackground(); thisObject.deleteTradingHistory.draw(); thisObject.chartAspectRatio.draw(); - thisObject.UsersModule.draw(); - thisObject.TeamsModule.draw(); - thisObject.KeyVaultModule.draw(); thisObject.playStopButton.draw(); }