setInterval(function(x){ repaint(x); }(i), function(x){return x}(lines[i].updateTime));
function start(name) { console.log(name); } var ar = { one: 1000, two: 800, three: 2100}; for(prop in ar) setInterval(start.bind(null, prop), ar[prop]);
function start(name) { console.log(name); } var ar = { one: 1000, two: 800, three: 2100}; for(prop in ar) setInterval((function (p) { return function () { start(p); }; })(prop), ar[prop]);