On 12/1/06, Sam Collett <[EMAIL PROTECTED]> wrote:
> An perhaps have a method that returns you back to jQuery object?
> Calling it 'end' (or any other jQuery method name) may be confusing,
> something like 'endGrid'.

I don't think using .end() would be confusing. If it makes sense for a
plugin to use method chaining then why not use the standard for
returning state, .end(). If this type of functionality starts to be
required I would suggest including a standard way for plugins to
easily restore state (.end()) in the core. Destructive methods will be
no more in 1.1, so I don't think .end() will be around either.
However, it seems to make sense (to me at least) to be used in
situations like these.

$('#foo').grid({data:data}).show()
    .gridController() // load grid object
        .scrollToRow(6).anything().else().with().grid()
    .end(); // back to jQuery

--
Brandon Aaron

_______________________________________________
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/

Reply via email to