MyObject = function() {
this.a = "a";
this.func = function() {
this.a = "b";
console.log(this);
}
}
.....
m = new MyObject();
$(li).bind('click',m.func);
I want: this
in this.func references on the surrounding MyObject object.
I get: this
references on <li>
(thats what the console logs).