I'll look at the properties of the swc and see what I see.  But I think we
were talking the samething.

 

<mx:Canvas xmlns:mx="blah" xmlns:thirdparty="com.blah.blah.*">

   <thirdparty:FooControl id="whatever"/>

</mx:Canvas>

I am assuming he extending the Canvas class here.  If he was to leave off
the xmlns:thirdparty.. And then just type <FooControl       then ctrl+space
it would add the xmlns to the Canvas node.  But thanks for the tip on the
swc props.  I'll take a look.

 

Dale

 

 

From: [email protected] [mailto:[email protected]] On Behalf Of Douglas Knudsen
Sent: Friday, March 27, 2009 5:29 PM
To: [email protected]
Subject: Re: [AFFUG Discuss] Best practice

 

Me thinks Charlie and Dale are speaking Apples to Oranges :)  Or maybe I got
Lemons on the mind.

What Charlie mentions is that you can in fact spell out the namespace on
every MXML node.  I've seen some folks do this, seeming as dedicated
followers of fashionable XML standards.  Most cases I do not see this use,
rather the namespace is listed once in the root tag.

Dale, the namespace that appears when the automagicness happens can be
defined in properties of the swc and some third-parties use the URI of the
namespace.  Any lookups to these should be getting cached in Eclispe for a
bit.  

Douglas Knudsen
http://www.cubicleman.com
this is my signature, like it?



On Fri, Mar 27, 2009 at 5:18 PM, Dale Bronk <[email protected]> wrote:

Next time you are in your mxml class, try and type the first few letters of
the component you want from a third party swc.  Then control + space for
code complete.  Not only does it code complete the mxml node, it will also
automatically add the xmlns for you.  That is when I'm getting the url based
namespace.

 

Oh well, just a bit more typing.

 

Thanks,

Dale

 

From: [email protected] [mailto:[email protected]] On Behalf Of Charlie Hubbard
Sent: Friday, March 27, 2009 5:12 PM
To: [email protected]
Subject: Re: [AFFUG Discuss] Best practice

 

I've always gone local configuration like you specified, but I always put it
at the top of my document like:

 

<mx:Canvas xmlns:mx="blah" xmlns:thirdparty="com.blah.blah.*">

   <thirdparty:FooControl id="whatever"/>

</mx:Canvas>

 

When I put it at the top it code completes for me just fine, but doesn't add
the ns stuff on every node of it.  In fact it won't code complete for me
until I put it up there.  After that it works perfectly fine.  Don't know if
that helps.

 

Charlie

 

On Fri, Mar 27, 2009 at 3:53 PM, Dale Bronk <[email protected]> wrote:

I have a swc from a vendor.  I drop it in my project.  Any time I use code
complete on one of their controls in my mxml file is adds the xmlns like so:

 

xmlns:comps=http://www.theirco.com/2007/blah/blah

 

I've been having my developers change this to the use the swc like so:

 

Xmlns:comps="org.theirco.blah.blah.*"

 

Is there a best practice on this?  I've always taken the route of why
specify a lookup to the web when you have everything you need local.  But it
is a pain that every time we use code complete on one of their components it
adds a url to the namespace rather than just use the swc in the project.

 

Thanks,

Dale

 


------------------------------------------------------------- 
To unsubscribe from this list, simply email the list with unsubscribe in the
subject line 

For more info, see http://www.affug.com 
Archive @ http://www.mail-archive.com/discussion%40affug.com/ 
List hosted by FusionLink <http://www.fusionlink.com>  
------------------------------------------------------------- 

 


------------------------------------------------------------- 
To unsubscribe from this list, simply email the list with unsubscribe in the
subject line 

For more info, see http://www.affug.com 
Archive @ http://www.mail-archive.com/discussion%40affug.com/ 
List hosted by FusionLink <http://www.fusionlink.com>  
------------------------------------------------------------- 

 




-------------------------------------------------------------
To unsubscribe from this list, simply email the list with unsubscribe in the 
subject line

For more info, see http://www.affug.com
Archive @ http://www.mail-archive.com/discussion%40affug.com/
List hosted by http://www.fusionlink.com
-------------------------------------------------------------

Reply via email to