Setting handlers after creation

Hi,

Basically when you create an enyo Control you specify handlers this way:

enyo.kind({
name: "MyKind",
components: [
{name: "myControl", content: "my content", ontap: "myHandler"}
]

myHandler: function(inSender, inEvent) {
alert("myControl tapped!");
}
})
But is it possible to affect handler after the control has been created, like this:
    this.$.myControl.ontap = enyo.bind(this, this.myHandler)
Of course this doesn't work, but is there any similar way to do this using enyo?

Comments

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Sign In with Twitter