[jquery-ui] Re: Request for comments: Lazy events binding.

2009-01-13 Thread Scott González
I don't see how binding an event handler and passing in the widget instance is any cleaner than creating a closure and referencing the instance that you already have. In fact, this looks like it just causes an increase in the amount of code needed to bind the event handlers. What's awkward or

[jquery-ui] Re: Request for comments: Lazy events binding.

2009-01-13 Thread h3
In fact, this looks like it just causes an increase in the amount of code needed to bind the event handlers. In my example yes, because it was a simplified scenario. Your method most likely is more efficient with small codebase, but when I deal with many components and events it does get

[jquery-ui] Re: Request for comments: Lazy events binding.

2009-01-13 Thread Scott González
On Jan 13, 10:33 am, h3 hainea...@gmail.com wrote: In my example yes, because it was a simplified scenario. Your method most likely is more efficient with small codebase, but when I deal with many components and events it does get ugly. The dialog plugin is built entirely in this fashion and