From c8c4edc2fd30af8ef4b67d56c3c65974ff25e37e Mon Sep 17 00:00:00 2001 From: Alon Levy Date: Sun, 10 Aug 2014 17:30:30 +0300 Subject: more 'use strict' and fallout handling Just defining some variables instead of them becoming properties on the global object Some whitespace fixes too. --- scripts/gant.js | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'scripts/gant.js') diff --git a/scripts/gant.js b/scripts/gant.js index 9b7fed4b..a89f9035 100644 --- a/scripts/gant.js +++ b/scripts/gant.js @@ -1,3 +1,4 @@ +"use strict" function checkSwitch(checkswitch) { @@ -26,7 +27,7 @@ function checkSwitch(checkswitch) { $('body').scrollLeft(scrollValue); graphstate = "GANTT"; - + graph.update(); $('.status').fadeIn(600); @@ -95,7 +96,7 @@ function initAxis() { ///update interval var timeDiff = Math.abs(max.getTime() - min.getTime()); var diffDays = timeDiff / (1000 * 3600 * 24); - w=Math.round(diffDays*15-100); + var w = Math.round(diffDays * 15 - 100); graphinterval = w / diffDays; @@ -130,7 +131,7 @@ function initAxis() { return i * row_height + paddingTop + bar_start_offset; } - labelY = function (i) { + var labelY = function (i) { return i * row_height + paddingTop + bar_start_offset + 13; } -- cgit v1.3.1