I think Canvas is the way to go...
 
Note that I meant that you could get the info from the Sprite.loaderInfo.loaderURL and set it on the mx.messaging.config.LoaderConfig.mx_internal::_url property, though this involves using a mx.core.mx_internal namespace which I don't believe is "public" and hence guaranteed to be supported going forward.


From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Jim Robson
Sent: Thursday, October 19, 2006 11:41 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: FDS and componentized development: Bug?

It seems like initializing mx.messaging.config.LoaderConfig.url would
have essentially the same drawback as setting the endpoint in
ActionScript - it would create a situation where I would need to
maintain the URL in ActionScript. Or am I misunderstanding you?

In any case, I think it's OK to use Canvas as the base class, because
it doesn't seem to add excessive weight to the app. But I am very much
open to better ideas!

Thanks for the explanation

-Jim

--- In [EMAIL PROTECTED]ups.com, "Peter Farland" <[EMAIL PROTECTED].> wrote:
>
> > I discovered something interesting. The original ActionScript class
> > extended Sprite. I changed this to Canvas, and now it works without
> > setting the endpoint in ActionScript. So I now have what I originally
> > wanted, except that I needed to extend Canvas to get it.
>
>
> *lightbulb illuminates* I know what the problem is now. If your channel
> endpoint has relative tokens in them, such as {server.name} and
> {server.port}, then these need to be resolved at runtime based on the
> URL used to load the SWF. The way that the channel gets this information
> is through the mx.messaging.config.LoaderConfig.url property, which is
> initialized when the main mx.managers.SystemManager starts up (as it is
> the one that has access to the root DisplayObject.loaderInfo).
>
> So, if you do need to use Sprite, then you could either avoid the
> relative tokens in your XML config for the channel or we'll need to get
> you to initialize the mx.messaging.config.Loader config.
>
> Pete
>

__._,_.___

--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com





SPONSORED LINKS
Software development tool Software development Software development services
Home design software Software development company

Your email settings: Individual Email|Traditional
Change settings via the Web (Yahoo! ID required)
Change settings via email: Switch delivery to Daily Digest | Switch to Fully Featured
Visit Your Group | Yahoo! Groups Terms of Use | Unsubscribe

__,_._,___

Reply via email to