in the setup function of a view I added a button with this event handler:
Code:
onClick: function (dialog) {
this.trigger('myCustomEvent');
dialog.close();
}.bind(this);
Code:
[FONT=courier new]this.listenToOnce(view, 'myCustomEvent', function () {
alert("event activated!");
// execute additional code...
view.close();
}.bind(this));[/FONT]
