I make it work overrading this function, but I don' t know why this is the
convenient way.


updateDisplayList

*override* *protected* *function* updateDisplayList(unscaledWidth:Number,
unscaledHeight:Number):*void*{

*if*(*this*._autoPlay && *this*.source!=*null*){

*this*.play();

}

}
If autoplay is true and source has the info, then play the music.





On Mon, Jul 7, 2008 at 12:54 PM, Tracy Spratt <[EMAIL PROTECTED]> wrote:

>    That would be a good candidate for a setter funcion.
>
> Tracy
>
>
>  ------------------------------
>
> *From:* flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] *On
> Behalf Of *Fernando Wermus
> *Sent:* Monday, July 07, 2008 3:26 PM
> *To:* flexcoders@yahoogroups.com
> *Subject:* Re: [flexcoders] loading attributes in a flex custom tag
>
>
>
> What about the order? Flex loads randomly the attributes. I have one called
> autoplay that if it is set in true play a song, but first I need Flex sets
> the url attribute. How can I manage this?
>
>
>
> Thnks
>
> On Mon, Jul 7, 2008 at 10:50 AM, Tracy Spratt <[EMAIL PROTECTED]>
> wrote:
>
> Don't set them in the constructor, implement them as public properties.  If
> variables, make the [Bindable], or use getter/setter methods for full
> control.
>
>
>
> Tracy
>
>
>  ------------------------------
>
> *From:* flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] *On
> Behalf Of *Fernando Wermus
> *Sent:* Monday, July 07, 2008 1:30 PM
> *To:* flexcoders@yahoogroups.com
> *Subject:* [flexcoders] loading attributes in a flex custom tag
>
>
>
> Hi all!
>
>      I have a custom component made by myself. I have to asign the values
> from the tag's attributes to some object when they are being created in the
> constructor custom component time. The problem is that Flex doesn't load the
> attributes when it calls the the constructor and therefore I cant
> constructor the component. I hope you understand.
>
>
>
> Thanks!
>
> --
> Fernando Wermus.
>
> www.linkedin.com/in/fernandowermus
> http://mientretiempo.blogspot.com/
>
>
>
>
> --
> Fernando Wermus.
>
> www.linkedin.com/in/fernandowermus
> http://mientretiempo.blogspot.com/
>
> 
>



-- 
Fernando Wermus.

www.linkedin.com/in/fernandowermus
http://mientretiempo.blogspot.com/

Reply via email to