Switch to 24 hs in a clever way

This commit is contained in:
Luis Fernando Molina committed 2020-03-03 21:12:03 +01:00
1 parent a2d49d7b0b
commit 74c9a7de3c
5 files changed
+40 -11

No files matched your search

+10 -1
View File
@@ -529,9 +529,18 @@ function newTimeMachine () {
function drawBackground () {
drawChartsBackground()
if (thisObject.container.frame.isInViewPort()) {
let maxElementsPlotted = 0
for (let i = 0; i < thisObject.timelineCharts.length; i++) {
let timelineChart = thisObject.timelineCharts[thisObject.timelineCharts.length - i - 1]
timelineChart.drawBackground()
let elementsPlotted = timelineChart.drawBackground()
if (elementsPlotted !== undefined) {
if (elementsPlotted > maxElementsPlotted) {
maxElementsPlotted = elementsPlotted
}
}
}
if (thisObject.timeFrameScale !== undefined) {
thisObject.timeFrameScale.adjustTimeFrame(maxElementsPlotted)
}
}
}