From b815e553dbc6e29403305ce1dde35bf8768ed8f5 Mon Sep 17 00:00:00 2001 From: Luis Fernando Molina Date: Wed, 21 Feb 2018 14:59:07 +0100 Subject: [PATCH] layerStatus = pLayerStatus; --- .vs/AAOlivia-Plotter/v15/.suo | Bin 17920 -> 17920 bytes Candlestick.js | 21 +++++++++++---------- 2 files changed, 11 insertions(+), 10 deletions(-) diff --git a/.vs/AAOlivia-Plotter/v15/.suo b/.vs/AAOlivia-Plotter/v15/.suo index b9c2e244a13ba870c88652332816aa7b83805320..ffb240e45a82bd20176502ecb3295df1f984bd6e 100644 GIT binary patch delta 161 zcmZqZVQlDO+>pb>YS3adQF?PB6FVd0-OZKEpP5)c==~R$*<8p55n-pb>TJWWE2ixXCCU!=~>zgZ?KQplgv>j~Z-dxBA5n-kh{^LDWF~W1Hf?T^&zHa=v176U6WitkmWiyA?Tid?un5TJ1M+x)n0d0GW83Bf S_KD0WN)`Z>Xrd``U;+S8M=SvV diff --git a/Candlestick.js b/Candlestick.js index e6a146c33..ec731f879 100644 --- a/Candlestick.js +++ b/Candlestick.js @@ -1,12 +1,6 @@ function newAAMastersAAOliviaCandlesticks() { - var candles = []; - var plotArea = newPlotArea(); - - let timePeriod; - var datetime; - - var candlesticks = { + let candlesticks = { onLayerStatusChanged: onLayerStatusChanged, currentCandle: undefined, positionAtDatetime: positionAtDatetime, @@ -26,16 +20,25 @@ container.zoom.containerName = "AAMasters AAOlivia Candlesticks"; container.frame.containerName = "AAMasters AAOlivia Candlesticks"; + let candles = []; + let plotArea = newPlotArea(); + + let timePeriod; + let datetime; + let marketFile; let fileCursor; let layerStatus = 'off'; let fileCache; + let fileCursorCache; return candlesticks; - function initialize(pExchange, pMarket, pDatetime, pTimePeriod, chartLayersPanel, callBackFunction) { + function initialize(pExchange, pMarket, pDatetime, pTimePeriod, pLayerStatus, callBackFunction) { + + layerStatus = pLayerStatus; let cursorCacheInProgress = false; let finaleStepsInProgress = false; @@ -93,8 +96,6 @@ recalculateScale(); // With any of the market files we can calculate the scale. - layerStatus = chartLayersPanel.getLayerStatus(chartLayersPanel.layerNames.OLIVIA_CANDLES); - recalculateCandles(); postitionViewPort();