// begin signals
this.loginSignal
this.init = function(){
// init signals
this.loginSignal = new t.store.helpers.Signal;
// map events
$('[value]="login"', this.node).click(this.login)
}
this.login = function(){
// this will dispatch an event that will be catched by the controller
// but this is not refering to this class
// and the next line fails :s
this.loginSignal.dispatch();
}
es jetzt funktioniert iWie bekomme ich das von einem Objekt in einem Handler für ein Klickereignis in jquery?
var $this = this;
diese Zeile und $this
statt this
verwenden müssen hinzufügen:
noch klarer Weg, um S? danke
auf einem anderen Hinweis, '[Wert] =" Login "' sollte wahrscheinlich '[Wert =" Login "]' sein –