I didn't think that necessarily meant 'creation complete' according to the doc's, maybe I misunderstood?
--- In flexcoders@yahoogroups.com, Alex Harui <[EMAIL PROTECTED]> wrote: > > So what's wrong with using the "initialized" property? > > From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of cwicky99 > Sent: Monday, October 27, 2008 7:37 AM > To: flexcoders@yahoogroups.com > Subject: [flexcoders] Re: Programmatically Determine if FlexEvent.CREATION_COMPLETE has been dispatche > > > So, say I missed the creation_complete event....or I can't listen for it. > > there is no programmatic way to ask a component if it is complete > right? I know UIComponent ( or something like that ) has the > "initialized" property. > > --- In flexcoders@yahoogroups.com<mailto:flexcoders%40yahoogroups.com>, "florian.salihovic" > <florian.salihovic@> wrote: > > > > Ah forgot to tell about that one. > > > > Or delete the reference manually. There have been some discussion > about weakReferences > > when registering eventlisteners.But that's another topic... > > > > Best regards. > > > > --- In flexcoders@yahoogroups.com<mailto:flexcoders%40yahoogroups.com>, "Josh McDonald" <dznuts@> wrote: > > > > > > Any time you're going to create a Dictionary to keep track of > things like > > > this, make sure to use weak references, by calling new > Dictionary(true) or > > > your app is likely to leak memory like a sieve :) > > > > > > And you might be able to get away with UIComponent.initialized, > depending on > > > what it is you're actually trying to achieve. > > > > > > -Josh > > > > > > On Mon, Oct 27, 2008 at 9:22 PM, florian.salihovic < > > > florian.salihovic@> wrote: > > > > > > > One way to do so: > > > > > > > > private var dictionaty:Dictionary = new Dictionary(); > > > > private var button:Button = new Button(); > > > > > > > > protected function initializeComponent():void > > > > { > > > > this.button.addEventListener(FlexEvent.CREATION_COMPLETE, > > > > onCreationComplete); > > > > this.dictionary[this.button] = false; > > > > } > > > > > > > > function onCreationComplete(event:Event):void > > > > { > > > > if (event.target == this.button) > > > > { > > > > dictionary[this.button] = true; > > > > } > > > > > > > > Working this way you can allways test, wether the > component-creation has > > > > been > > > > completed or not. > > > > > > > > Best regards from Germany > > > > > > > > --- In flexcoders@yahoogroups.com<mailto:flexcoders%40yahoogroups.com>, "cwicky99" <codecraig@> wrote: > > > > > > > > > > I need to programmatically determine if a component has dispatched > > > > > FlexEvent.CREATION_COMPLETE so that I know it has finished being > > > > > created as well as all of it's children. > > > > > > > > > > I don't see a "creationCompleted" property, is there some > other way to > > > > > tell? I know I can listen for the event I am wondering if > there is > > > > > some other way to tell that it had already happened. So I can > have > > > > > logic similar: > > > > > > > > > > if ( comp.creationCompleted ) > > > > > { > > > > > // do stuff to a child > > > > > comp.fooView.fooButton.addEventListener(...); > > > > > } > > > > > else > > > > > { > > > > > comp.addEventListener(FlexEvent.CREATION_COMPLETE, > handleCreation); > > > > > } > > > > > > > > > > > > > > > > > > > > > > > > > ------------------------------------ > > > > > > > > -- > > > > Flexcoders Mailing List > > > > FAQ: > http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt > > > > Alternative FAQ location: > > > > > https://share.acrobat.com/adc/document.do?docid=942dbdc8-e469-446f-b4cf- > > 1e62079f6847 > > > > Search Archives: > > > > http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! > Groups > > > > Links > > > > > > > > > > > > > > > > > > > > > > > > > -- > > > "Therefore, send not to know For whom the bell tolls. It tolls for > thee." > > > > > > Like the cut of my jib? Check out my Flex blog! > > > > > > :: Josh 'G-Funk' McDonald > > > :: 0437 221 380 :: josh@ > > > :: http://flex.joshmcdonald.info/ > > > > > >