I believe the list components calculate the visible space divided by the row
height and figure out how many rows to render. Visible being the amount of
rows the height and row height of the component will allow - not being total
rows in reference to amount of dataprovider items.

Not sure that is what you were asking. But you know me D, not always there,
but always pretending to be :)



-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Derek
Vadneau
Sent: Wednesday, January 25, 2006 2:09 PM
To: flashcoders@chattyfig.figleaf.com
Subject: [Flashcoders] Cellrenderer confirmation

Hi all,

I just want to verify a few things in case I've thought about this 
incorrectly.

I've built three cellrenderer classes for a datagrid.  I've got everything 
working but I'm trying to optimize the classes so things don't get cycled 
when they don't need to be.

Am I correct in assuming that a datagrid (and a list-based component in 
general) only produces X number of instances of a cellrenderer, where X is 
the number of VISIBLE rows, as opposed to TOTAL rows?

When I scroll, it's as if the rows cycle: 0-6 are visible.  Scroll so 7 is 
visible, but the cellrenderer in row 7 traces out data that was kept in 
row 0.

If that's the case, then you can't store row-specific information in a 
cellrenderer instance.  In which case, my optimizations are probably as 
good as they're going to get.

Also, I've searched through the archives and it seems the only way to 
trigger the change event, or any event, in the datagrid from the 
cellrenderer is to have the cellrenderer execute the dispatchEvent method. 
Is that the only way?  It seems a little hackish to me.  It does work, but 
you'd think there would be a mechanism in place to have the cellrenderer 
tell the datagrid that it wants to update the dataProvider.

Any thoughts?


Derek Vadneau


_______________________________________________
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


_______________________________________________
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Reply via email to