Dude, figured out why createLabel makes your text field invisible. Check this comment in the mx.controls.SimpleButton class for the createChildren method (called by extendee’s of UIObject):
create children objects. Components implement this method to create the subobjects in the component. Recommended way is to make text objects invisible and make them visible when the draw() method is called to avoid flicker on the screen.
Well blow me down… is that even possible? Anyway, makes sense now. I like how ever time I learn something, all of my current components are now wrong, hehe. Maybe I should just remain ignorant, then my code would R0cK!!!
Comments
7 responses to “createLabel Part Deux”
Hi Jesse,
Don’t you think that would be great that Nigel Pegg (as the creator of the v2 framework) post about things like this, so the Flash Community could benefit about all this knowledge…
Regards,
Carlos
I plead the 5th…
Don’t you think Nigel has a lot of work to do, and isn’t actually paid to make posts in his blog, although he wishes he could have the time to do all of what everyone wants?…
Regards,
nig
Hi Nig,
I’m not sure if I say something bad before. I’m not native English, and maybe my english isn’t as well as I would, but I translate your comment as if I’m unfortunate with my comment.
Just in case I want to apologize for any badly understood.
Sorry.
Carlos
Nah… don’t sweat it Carlos, nothing wrong with your comment.
Thanks Oscar, I’m thinking that I’m getting crazy with my poor english :).
nothing really that wrong with my answer either. Everyone’s cool here.