Hello, I've started using a declarative way for my event connections. I
would create an array with objects that define the different events and
its targets, and then call a generic connectEventMap() method that
would do the plumbing for me. An example would be:
var eventMap = [
{ name: 'credit', onkeyup: onValueKeyUp },
{ name: 'debit', onkeyup: onValueKeyUp },
{ name: 'creditNational', onkeyup: onNationalValueKeyUp, onchange:
onInputChange },
{ name: 'debitNational', onkeyup: onNationalValueKeyUp, onchange:
onInputChange },
{ tag: 'input', onblur: onInputBlur }
]
Could something like this be useful for MochiKit?
Regards,
Pablo
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"MochiKit" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/mochikit
-~----------~----~----~----~------~----~------~--~---