Mathew Byrne
unread,Oct 6, 2008, 2:14:06 AM10/6/08Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to chainjs
The current implementation of chain.js can be slow at times depending
on what your doing. I'm developing an app at the moment and would like
to display a loading screen to a user every time chain.js binds data
from a large data set to some DOM elements.
I also want to prevent impatient users from clicking through the
interface if loading takes more than a second or so.
I think it would be a good idea to provide a method for registering
callback functions, perhaps an argument to .chain()?
An example of what I'm talking about:
var loading = false,
list = $('#gallery_list')
.chain({
...
}, function () {
loading = false;
});
$('#gallery').click(function () {
var self = $(this),
item = self.items();
if (loading) {
return;
}
loading = true;
$('#gallery_images').items(item.images);
});