If it's in a container that uses a LayoutManager (not Canvas IIRC), and if the component in question isn't of a fixed size.
If you need to measure and position stuff in a component that's not always of a fluid size, you need to move your code into another method, and call it both from measure() and on CreationComplete and whenever you add a component. I'm not sure if it could be attached to invalidateDisplayList somehow, in case you do something that triggers an endless loop ;-) It's something I'll look into when I have more time, as I'm doing all my component adding in createChildren() and haven't had to deal with post CreationComplete changes. Alex, please correct me if I'm wrong in there somewhere, too! -J On Wed, May 14, 2008 at 10:18 AM, Mansour Raad <[EMAIL PROTECTED]> wrote: > Question - is it part of the lifecycle of the component ? > > Mansour > :-) > > > -----Original Message----- > From: [email protected] <flexcoders%40yahoogroups.com> on behalf > of Alex Harui > Sent: Tue 5/13/2008 8:07 PM > To: [email protected] <flexcoders%40yahoogroups.com> > Subject: RE: [flexcoders] Quick question - who calls > UIComponent.measure()? > > It is called by LayoutManager via validateSize() > > ________________________________ > > From: [email protected] <flexcoders%40yahoogroups.com> [mailto: > [email protected] <flexcoders%40yahoogroups.com>] On > Behalf Of Josh McDonald > Sent: Tuesday, May 13, 2008 4:33 PM > To: [email protected] <flexcoders%40yahoogroups.com> > Subject: [flexcoders] Quick question - who calls UIComponent.measure()? > > Hey guys, > > Since UIComponent.measure() is protected, does the container invoke it > via a round-about way, or is it simply called from a ResizeEvent.RESIZE > handler somewhere in UIComponent? > > -J > > -- > "Therefore, send not to know For whom the bell tolls. It tolls for > thee." > > :: Josh 'G-Funk' McDonald > :: 0437 221 380 :: [EMAIL PROTECTED] <josh%40gfunk007.com> <mailto: > [EMAIL PROTECTED] <josh%40gfunk007.com>> > > > -- "Therefore, send not to know For whom the bell tolls. It tolls for thee." :: Josh 'G-Funk' McDonald :: 0437 221 380 :: [EMAIL PROTECTED]

