- On Mon, Apr 30, 2007 at 07:43:06AM -0000, Binoy wrote:
> Hi,The more targets there are available to a drag and drop object, the
> I am new to yui. I have already posted one issue over here. But
> didn't get any reply :-( .
> I have created scheduler (like http://www.calendar.google.com). This
> contains a grid where the user can place events (schedules). The grid
> contains around 300 dropable (target) area and around 50 draggable
> elements. On body load i am initializing all my targets and onmouseover
> of the event I am making it as draggable. I have also given paging
> through ajax. So the user can drag one event from one page (eg: today)
> to another page (eg:tomorrow). All these things are working fine. But
> the performance of the application is gradually decreasing. I think I
> need to remove the items from cache.
> I am confused with removefromgroup, unreg, unregall and refreshcache.
> How can I improve the performance of the application ?
greater the performance impact. If performance is decreasing over time,
you are probably creating more drag and drop objects each time the user
changes from one page to another. "unreg" will unregister a drag and drop
instance. When you create a new set of drag and drop objects you can use
unreg to destroy the drag and drop objects that are no longer targetable.