From 0e64069d14f3edad32f8d6a3272930cc7108891a Mon Sep 17 00:00:00 2001 From: Luis Fernando Molina Date: Tue, 3 Mar 2020 21:12:24 +0100 Subject: [PATCH] switch to 24hs --- Candles.js | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/Candles.js b/Candles.js index 40c883bcd..915ece46e 100644 --- a/Candles.js +++ b/Candles.js @@ -263,7 +263,7 @@ thisObject.container.frame.draw(); - plotChart(); + return plotChart(); } catch (err) { @@ -469,7 +469,7 @@ function plotChart() { try { - + let elementsPlotted = 0 let lowResolution = false if (canvas.chartingSpace.viewport.zoomTargetLevel < ZOOM_OUT_THRESHOLD_FOR_PLOTTING_IN_LOW_RESOLUTION) { if (candles.length > 100) { @@ -691,6 +691,8 @@ browserCanvasContext.lineTo(candle.candlePoint3.x, candle.candlePoint3.y); browserCanvasContext.lineTo(candle.candlePoint4.x, candle.candlePoint4.y); browserCanvasContext.lineTo(candle.candlePoint1.x, candle.candlePoint1.y); + + elementsPlotted++ } browserCanvasContext.closePath(); @@ -746,7 +748,7 @@ thisObject.container.eventHandler.raiseEvent("Current Record Changed", currentCandle); } } - + return elementsPlotted } catch (err) { if (ERROR_LOG === true) { logger.write("[ERROR] plotChart -> err = " + err.stack); }