I have some javascript code (within an object) :
toggle: function() { var me = this; var handler = function() { me.progress() }; me.intervalId = setI
You can use ".bind()":
var handler = function() { this.progress(); }.bind(this);
New browsers have "bind()", and the Mozilla docs have a solid implementation you can use to patch older browsers.