Re: [flexcoders] Why would mx.controls.NavBar.dataProvider not accept an array of DisplayObject? (3.0.0)

2008-05-17 Thread Ernesto Casasín
Hi,



what if you use vs.dataProvider.removeItemAt(2) to remove completely  
the form button from your ButtonBar, later you could add it using  
vs.dataProvider.addItem(yourObject)



holpe it helps

>
> It's unfortunate that it is prevented though, as my goal was to
> selectively display ViewStack children buttons (instead of a mere
> ViewStack binding that displays buttons for each child), i.e.:
>
> 
> 
> 
> 
>  
> 
>
> I wanted my button bar not to show the "form button".
>
>
>

––
Ernesto Casasín
Abaco Digital, SL
José Pardo Sastrón, 7, 1
50001 Zaragoza
Tel: 34 976 29 79 80
Fax: 34 976 20 48 50






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

<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/flexcoders/

<*> Your email settings:
Individual Email | Traditional

<*> To change settings online go to:
http://groups.yahoo.com/group/flexcoders/join
(Yahoo! ID required)

<*> To change settings via email:
mailto:[EMAIL PROTECTED] 
mailto:[EMAIL PROTECTED]

<*> To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/



[flexcoders] flex3 sdk and eclipse 3.2

2008-05-17 Thread Gustavo Duenas
Hi, anyone knows a way to make eclipse 3.2 to work with the flex sdk?

regards,


Gustavo

P.s: any tutorial could be nice




RE: [flexcoders] XMLListCollection as dataProvider for ToggleButtonBar problem

2008-05-17 Thread Alex Harui
Sorry, that is this bug: https://bugs.adobe.com/jira/browse/SDK-11357

You'll have to convert to an ArrayCollection 

-Original Message-
From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Ernesto 
Casasín
Sent: Saturday, May 17, 2008 1:44 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] XMLListCollection as dataProvider for ToggleButtonBar 
problem

Hi all,

I'm trying to populate a ToggleButtonBar component with data hold on a 
XMLListCollection, but it throws an error

TypeError: Error #1034: Error cannot convert
mx.collections::[EMAIL PROTECTED] in mx.containers.ViewStack.
at mx.controls::NavBar/_setTargetViewStack()[E:\dev\3.0.x\frameworks
\projects\framework\src\mx\controls\NavBar.as:963]
at mx.controls::NavBar/checkPendingTargetStack()[E:\dev\3.0.x
\frameworks\projects\framework\src\mx\controls\NavBar.as:1049]
at mx.controls::NavBar/commitProperties()[E:\dev\3.0.x\frameworks
\projects\framework\src\mx\controls\NavBar.as:672]
at mx.controls::ButtonBar/commitProperties()[E:\dev\3.0.x\frameworks
\projects\framework\src\mx\controls\ButtonBar.as:501]
at mx.controls::ToggleButtonBar/commitProperties()[E:\dev\3.0.x
\frameworks\projects\framework\src\mx\controls\ToggleButtonBar.as:328]
at mx.core::UIComponent/validateProperties()[E:\dev\3.0.x\frameworks
\projects\framework\src\mx\core\UIComponent.as:5670]
at mx.managers::LayoutManager/validateProperties()[E:\dev\3.0.x
\frameworks\projects\framework\src\mx\managers\LayoutManager.as:519]
at mx.managers::LayoutManager/doPhasedInstantiation()[E:\dev\3.0.x
\frameworks\projects\framework\src\mx\managers\LayoutManager.as:669]
at Function/http://adobe.com/AS3/2006/builtin::apply()
at mx.core::UIComponent/callLaterDispatcher2()[E:\dev\3.0.x
\frameworks\projects\framework\src\mx\core\UIComponent.as:8460]
at mx.core::UIComponent/callLaterDispatcher()[E:\dev\3.0.x\frameworks
\projects\framework\src\mx\core\UIComponent.as:8403]

is it possible?

TIA

--
Ernesto Casasín
Abaco Digital, SL
José Pardo Sastrón, 7, 1
50001 Zaragoza
Tel: 34 976 29 79 80
Fax: 34 976 20 48 50






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





RE: [flexcoders] DateChooser setting displayedMonth, displayedYear does nothing

2008-05-17 Thread Alex Harui
I'd make a simple test case and see if it works there.  Are you sure
your compDateRange has two elements with valid values?



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of rleuthold
Sent: Saturday, May 17, 2008 6:05 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] DateChooser setting displayedMonth, displayedYear
does nothing



Hi,

I have a DateChooser in a popUp window. If I set the displayedMonth and
displayedYear 
properties on that DateChooser (after creating the popup), nothing
happens. The display is 
still on the month and year previously selected/displayed. Does anybody
have an idea ?

code (parent comp):

_datePickerWin =
DateRangerPopUp(PopUpManager.createPopUp(Application.application as 
DisplayObject, DateRangerPopUp, true));
_datePickerWin.compDateRange = _dateRange;

code (DateRangerPopup):
public function set compDateRange(dateRange:Array):void
{
_compDateRange = dateRange;

dateChooser.selectedRanges = [ {rangeStart: _compDateRange[0], rangeEnd:

_compDateRange[1] }];

dateChooser.displayedMonth = _compDateRange[1].month;
dateChooser.displayedYear = _compDateRange[1].fullYear;


Thank's rico



 


RE: [flexcoders] Re: bug in setMonth() method?

2008-05-17 Thread Alex Harui
Yes.  In Flex we have a GIGO policy.  "garbage in, garbage out".  We
have enough complaints about runtime memory usage, swf size and
performance that adding parameter checking was not practical.  The
player does some checking, but not everywhere as well for the same
reason.  That said, we hope to have time to use conditional compilation
to put in more dev-time checking in future releases, but if we do, I
don't want to hear complaints about why the debug version is so slow.



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Amy
Sent: Saturday, May 17, 2008 7:38 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: bug in setMonth() method?



--- In flexcoders@yahoogroups.com 
, "Alex Harui" <[EMAIL PROTECTED]> wrote:
>
> I would not guarantee results if you set values that are out of range.

So you think that it's ok to fail silently and return a nearly 
appropriate value rather than throwing an error?



 


RE: [flexcoders] Re: Dispatching an event from an inline itemrenderer

2008-05-17 Thread Alex Harui
It looks like you're listening for the event from currentStickNote,
which is not the renderer that dispatches the event.



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of jeffreyr6915
Sent: Saturday, May 17, 2008 7:33 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: Dispatching an event from an inline
itemrenderer



--- In flexcoders@yahoogroups.com 
, "jeffreyr6915" <[EMAIL PROTECTED]> wrote:
>
> Hi Tracy,
> 
> I tried to remove as much code as possible. Thanks
> 
> 
> DailyUpdateView.mxml
> ---
> 
> public function initApp():void
> { 
> 
> //Event Listener
>
currentStickyNote.addEventListener("taskUpdate",currentStickyViewHandler
);
> 
> }
> 
> 
> private function
currentStickyViewHandler(event:UpdateScrumTaskEvent):void
> {
> currentStickyNote.category = event.category;
> }
> 
> 
>  title="Planning" id="planningPanel">
>  height="499" y="0" x="0" 
> dragEnabled="true" dropEnabled="true" dragMoveEnabled="true" 
> themeColor="#FF"
> dragDrop="dragDropHandler(event)" width="348">
> 
> 
> http://www.adobe.com/2006/mxml
 "
> horizontalScrollPolicy="off" verticalScrollPolicy="off" 
> mouseOver="showLargeSticky()">
> 
>  category="{data.category}" description="{data.description}"
> visible="true"/>
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> UpdateScrumTaskEvent
> -
> package com.intuit.scrum.events
> {
> import flash.events.Event;
> 
> public class UpdateScrumTaskEvent extends Event
> {
> 
> public var category:String;
> public var description:String;
> public var developer:String;
> public var developerHrs:int;
> public var qa:String;
> public var qaHrs:int;
> public var priority:int;
> 
> public function UpdateScrumTaskEvent(type:String,category:String,
> description:String,
> 
> developer:String,developerHrs:int,qa:String,qaHrs:int,priority:int)
> {
> super(type);
> this.category = category;
> this.description = description;
> this.developer = developer;
> this.developerHrs = developerHrs;
> this.qa = qa;
> this.qaHrs = qaHrs;
> this.priority = priority;
> }
> 
> }
> }
>

Can someone please help me with this? Thanks



 


RE: [flexcoders] Re: a simple question of BitmapData

2008-05-17 Thread Alex Harui
SWFLoader doesn't get going until you addChild it.  If you use
flash.display.Loader, you might be able to load w/o addChild



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of flexawesome
Sent: Saturday, May 17, 2008 3:16 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: a simple question of BitmapData




Hi there, I have updated the code ( enabled line5 ) and get the 
duplicate copy of gif file. 

Is there a way to prevent to use addChild but still can get the copy 
of the image?

Cheers

http://www.privatepaste.com/29lCTCERRY
 

--- In flexcoders@yahoogroups.com 
, "flexawesome" <[EMAIL PROTECTED]> 
wrote:
>
> Hi there,
> 
> do you know how can I use it to duplicate the image? It seems 
doesn't 
> work. any ideas?
> 
> Thank you
> 
> loader = new SWFLoader();
> loader.addEventListener(Event.COMPLETE, Bitmapdata) 
> 
> loader.source 
= "http://us.i1.yimg.com/us.yimg.com/i/us/nt/ma/ma_tech-
 
> grp_1.gif"
> //addChild(loader);
> 
> 
> private function oBitmapdata(e:Event):void
> {
> 
> var img:Image = new Image();
> var data:BitmapData = Bitmap(loader.content).bitmapData;
> var bitmap:Bitmap = new Bitmap(data);
> 
> img.addChild(bitmap)
> 
> addChild(img);
> 
> }
>



 


[flexcoders]Create a new flex project from ANT

2008-05-17 Thread dorkie dork from dorktown
I'm having a long day. I need to create a new Flex Project from ANT from
within Flex Builder. I normally just goto File > New > Flex Project but I
need to automate it. Can someone give me a hint how to do this?

best cigars,
dorkiedorkfromdorktown


Re: [flexcoders] Re: a simple question of BitmapData

2008-05-17 Thread Sherif Abdou
I am guessing you need to do a deep copy
private function clone(source:Object):* {
var copier:ByteArray = new ByteArray();
copier.writeObject(source);
copier.position = 0;
return(copier.readObject());
}
or use the ObjectUtil, if i understand you correctly. 


- Original Message 
From: flexawesome <[EMAIL PROTECTED]>
To: flexcoders@yahoogroups.com
Sent: Saturday, May 17, 2008 5:16:15 PM
Subject: [flexcoders] Re: a simple question of BitmapData



Hi there, I have updated the code ( enabled line5 ) and get the 
duplicate copy of gif file. 

Is there a way to prevent to use addChild but still can get the copy 
of the image?

Cheers

http://www.privatep aste.com/ 29lCTCERRY

--- In [EMAIL PROTECTED] ups.com, "flexawesome"  
wrote:
>
> Hi there,
> 
> do you know how can I use it to duplicate the image? It seems 
doesn't 
> work. any ideas?
> 
> Thank you
> 
> loader = new SWFLoader();
> loader.addEventList ener(Event. COMPLETE, Bitmapdata) 
> 
> loader.source 
= "http://us.i1. yimg.com/ us.yimg.com/ i/us/nt/ma/ ma_tech-
> grp_1.gif"
> //addChild(loader) ;
> 
> 
> private function oBitmapdata( e:Event): void
> {
> 
>   var img:Image = new Image();
>   var data:BitmapData = Bitmap(loader. content). bitmapData;
>   var bitmap:Bitmap = new Bitmap(data) ;
> 
>   img.addChild( bitmap)
> 
>   addChild(img) ;
> 
> }
>




  

[flexcoders] Re: Dispatching an event from an inline itemrenderer

2008-05-17 Thread jeffreyr6915
--- In flexcoders@yahoogroups.com, "jeffreyr6915" <[EMAIL PROTECTED]> wrote:
>
> Hi Tracy,
> 
> I tried to remove as much code as possible. Thanks
> 
> 
> DailyUpdateView.mxml
> ---
> 
> public function initApp():void
>   { 
>   
>   //Event Listener
>
currentStickyNote.addEventListener("taskUpdate",currentStickyViewHandler);
>   
>   }
> 
> 
> private function
currentStickyViewHandler(event:UpdateScrumTaskEvent):void
>   {
>   currentStickyNote.category = event.category;
>   }
> 
> 
>  title="Planning" id="planningPanel">
>dataProvider="{plannedTaskColl}"
> height="499" y="0" x="0"  
>   dragEnabled="true" dropEnabled="true" 
> dragMoveEnabled="true" 
> themeColor="#FF"
>   dragDrop="dragDropHandler(event)" width="348">
>   
>   
>xmlns:mx="http://www.adobe.com/2006/mxml";
> horizontalScrollPolicy="off" verticalScrollPolicy="off"  
>   mouseOver="showLargeSticky()">
>  
>id="stickyNoteSmall"
> category="{data.category}" description="{data.description}"
> visible="true"/>
>   
>   
>   
> 
> 
>   
>   
>   
>   
>   
> 
> 
> UpdateScrumTaskEvent
> -
> package com.intuit.scrum.events
> {
> import flash.events.Event;
> 
> public class UpdateScrumTaskEvent extends Event
> {
> 
> public var category:String;
> public var description:String;
> public var developer:String;
> public var developerHrs:int;
> public var qa:String;
> public var qaHrs:int;
> public var priority:int;
> 
> public function UpdateScrumTaskEvent(type:String,category:String,
> description:String,
> 
> developer:String,developerHrs:int,qa:String,qaHrs:int,priority:int)
> {
> super(type);
> this.category = category;
> this.description = description;
> this.developer = developer;
> this.developerHrs = developerHrs;
> this.qa = qa;
> this.qaHrs = qaHrs;
> this.priority = priority;
> }
> 
> }
> }
>

Can someone please help me with this? Thanks



RE: [flexcoders] Changing parents throught Drag & Drop

2008-05-17 Thread Rick Winscot
Can you share a code sample? Without taking a look at what you are doing. we
could be just shooting blindly at what the problem is. First thing is first
- are you removing the child from its present container and then re-adding
it to the new target? The drag manager doesn't by default handle those kinds
of things.

 

Rick Winscot

 

From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Daniel
Sent: Saturday, May 17, 2008 12:30 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Changing parents throught Drag & Drop

 

Hey guys,

Here's the scenario... I have a list of things displayed in a Tree.
You can drag one of them, and drop it in a Container. The Container is
in charge of creating what the dragged object specifies, generally an
UIComponent. If the object is dropped inside a Container, it
succesfully sets the right parent for the object. Once the component
is created, it can still be dragged around. The problem is, once i've
created the object and the parent has been set, if the object is
dropped on other Container the parent property doesn't change, it's
always dropped on the Container it was initially dropped.

Every Container object has dragEnter and dragDrop handlers. The drag &
drop is done using the DragManager.

Why can't I change parents on drag & drop?

 



Re: [flexcoders] TabNavigator children

2008-05-17 Thread Paul Andrews
Why would you have a TabNavigator - something that supports the tabbed 
interface paradigm, showing only one tab at a time, then go ahead and try 
and make it behave like something else?

Why don't you have a TabBar, then manage the displayed pages (containers) 
yourself? You can then dispose of the TabBar and still have the containers 
to work with.

Paul
- Original Message - 
From: "Daniel" <[EMAIL PROTECTED]>
To: 
Sent: Saturday, May 17, 2008 5:43 PM
Subject: [flexcoders] TabNavigator children


> Hey guys,
>
> Maybe this is easy, but I just can't figure it out! I have a
> TabNavigator with a few tabs. At some point at run time I want to
> dispose the TabNavigator and draw the containers in its tabs. The
> problem is when I get the TabNavigator children and draw them on
> screen it draws only one tab (the tab is selected by the time). The
> unselected tabs exist, but are not drawn on screen. I've tried to
> explicitly setting the position and size of each of them without success.
>
> How can I draw all the tabs?
>
>
> 
>
> --
> Flexcoders Mailing List
> FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
> Search Archives: 
> http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! Groups 
> Links
>
>
>
> 



RE: [flexcoders] Re: a simple question of BitmapData

2008-05-17 Thread Jim Hayes
Call loader.load() rather than addchild() ?
 
Perhaps I don't understand your question? 
 
-Original Message-
From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of flexawesome
Sent: 17 May 2008 23:16
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: a simple question of BitmapData
 

Hi there, I have updated the code ( enabled line5 ) and get the 
duplicate copy of gif file. 

Is there a way to prevent to use addChild but still can get the copy 
of the image?

Cheers

http://www.privatepaste.com/29lCTCERRY
 

--- In flexcoders@yahoogroups.com 
, "flexawesome" <[EMAIL PROTECTED]> 
wrote:
>
> Hi there,
> 
> do you know how can I use it to duplicate the image? It seems 
doesn't 
> work. any ideas?
> 
> Thank you
> 
> loader = new SWFLoader();
> loader.addEventListener(Event.COMPLETE, Bitmapdata) 
> 
> loader.source 
= "http://us.i1.yimg.com/us.yimg.com/i/us/nt/ma/ma_tech-
 
> grp_1.gif"
> //addChild(loader);
> 
> 
> private function oBitmapdata(e:Event):void
> {
> 
> var img:Image = new Image();
> var data:BitmapData = Bitmap(loader.content).bitmapData;
> var bitmap:Bitmap = new Bitmap(data);
> 
> img.addChild(bitmap)
> 
> addChild(img);
> 
> }
>
 

__
This communication is from Primal Pictures Ltd., a company registered in 
England and Wales with registration No. 02622298 and registered office: 4th 
Floor, Tennyson House, 159-165 Great Portland Street, London, W1W 5PA, UK. VAT 
registration No. 648874577.

This e-mail is confidential and may be privileged. It may be read, copied and 
used only by the intended recipient. If you have received it in error, please 
contact the sender immediately by return e-mail or by telephoning +44(0)20 7637 
1010. Please then delete the e-mail and do not disclose its contents to any 
person.
This email has been scanned for Primal Pictures by the MessageLabs Email 
Security System.
__

[flexcoders] Re: a simple question of BitmapData

2008-05-17 Thread flexawesome

Hi there, I have updated the code ( enabled line5 ) and get the 
duplicate copy of gif file. 

Is there a way to prevent to use addChild but still can get the copy 
of the image?

Cheers



http://www.privatepaste.com/29lCTCERRY

--- In flexcoders@yahoogroups.com, "flexawesome" <[EMAIL PROTECTED]> 
wrote:
>
> Hi there,
> 
> do you know how can I use it to duplicate the image? It seems 
doesn't 
> work. any ideas?
> 
> Thank you
> 
> loader = new SWFLoader();
> loader.addEventListener(Event.COMPLETE, Bitmapdata)   
>   
> loader.source 
= "http://us.i1.yimg.com/us.yimg.com/i/us/nt/ma/ma_tech-
> grp_1.gif"
> //addChild(loader);
> 
> 
> private function oBitmapdata(e:Event):void
> {
>   
>   var img:Image = new Image();
>   var data:BitmapData = Bitmap(loader.content).bitmapData;
>   var bitmap:Bitmap = new Bitmap(data);
>   
>   img.addChild(bitmap)
>   
>   addChild(img);
> 
> }
>




Re: [flexcoders] ColdFusion Structures in Flex

2008-05-17 Thread Mike Chabot
If you are new to Flex you can use a generic array collection to
populate a datagrid without any major issues. They work fine. You can
go back later and turn it into an array of typed objects if you
encounter a situation where this is beneficial.

As for your question, the list of data sources is probably very small.
I would send all the details into Flex with one call. It will be
easier to code and I doubt you are going to noticably impact RAM usage
or bandwidth by doing this.

-Mike Chabot

On Sat, May 17, 2008 at 3:15 PM, Dan Vega <[EMAIL PROTECTED]> wrote:
> Here is what I am trying to do and it may make more sense. I have an object
> coming back from ColdFusion that contains a list of datasource names. When
> reading through the docs I can tell i need an arrayCollection or
> XmlLIstCollection to use as the data provider.
>
> I also need to list the field names for each datasource underneath that so
> should I just build that completely on the cf side before passing it back or
> when the datasource + is clicked retrieve a list of field names.
>
>
> 
> http://www.adobe.com/2006/mxml"; layout="absolute"
> creationComplete="init()">
>
> 
> 
> 
>
>  source="cfide.adminapi.administrator">
> 
> 
>
>  source="cfide.adminapi.datasource">
>  result="getDataSourcesHandler(event)"/>
> 
>
> 
> 
> 
> 
> 
> 
>
>
> 


RE: [flexcoders] Re: How to tell if variable is an int, uint, or a Number?

2008-05-17 Thread Alex Harui
Aren't there still inefficiencies in accessing packed values that aren't
on 32-bit alignments?



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Glenn Williams
Sent: Saturday, May 17, 2008 7:24 AM
To: flexcoders@yahoogroups.com
Subject: RE: [flexcoders] Re: How to tell if variable is an int, uint,
or a Number?



A little off topic I know but I really hope that at some point the Flash
Player extends it number handling to include byte, word, long etc. I
hate using int or uint when I know I really just need a byte or
whatever.

It just pains me.

I suppose that's due to my machine code background, but it always feels
so wasteful.

Glenn Williams

tinylion development UK

www.flex-ria.com

www.tinylion.co.uk

From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of EECOLOR
Sent: Saturday, May 17, 2008 11:51 AM
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] Re: How to tell if variable is an int, uint,
or a Number?

I would recommend you to use the getQualifiedClassName method, it is a
bit less expensive than the describeType method.


Greetz Erik



On 5/16/08, Paul Whitelock <[EMAIL PROTECTED]
 > wrote:

Alrighty then, I filed a bug report since the following outputs "int":

var uintVar:uint = 5; trace(describeType(uintVar)[EMAIL PROTECTED]());

--- In flexcoders@yahoogroups.com 
, "Gordon Smith" <[EMAIL PROTECTED]> wrote:
>
> I think there is a conceptual distinction between the runtime type of
an
> AS3 value and the compile-time type of a var or parameter that holds
> such a value.
> 
> 
> 
> The 'is' operator works on values. A value like 5 'is' both an int, a
> uint, and a Number because it is a legal value in the set of possible
> values for each of these types.
> 
> 
> 
> But I would expect a var declared as
> 
> 
> 
> var u:uint;
> 
> 
> 
> to report itself via describeType() as a uint, just like int and
Number
> do. It seems like a bug that it doesn't.
> 
> 
> 
> Gordon Smith
> 
> Adobe Flex SDK Team
> 
> 
>

 


[flexcoders] Getting HTTP status code with HTTPService

2008-05-17 Thread dave_defusion
I've been digging through the documentation and debugged the
HTTPResultEvent but I can't see anyway to get the HTTP status code
using HTTPService, am I wrong is there some way to get it?



Re: [flexcoders] Why would mx.controls.NavBar.dataProvider not accept an array of DisplayObject? (3.0.0)

2008-05-17 Thread Fiouz
On Sat, May 17, 2008 at 6:24 PM, Manish Jethani
<[EMAIL PROTECTED]> wrote:
>> What is the reason behind throwing an error when an array of
>> DisplayObject is given? Why would I have to wrap my DisplayObject
>> instances in order to prevent this error?
>
> The idea was to prevent you from doing this:
>
>  
>
>
>  
>
> If the above were allowed, you'd think that your click handler would
> get called, but in fact the ButtonBar (which is based on NavBar) would
> actually be using the array as a data provider to create its own
> Button objects; thus, your Button objects wouldn't get used as
> children of the ButtonBar, they would just serve as data objects.
>
> So, why not the ButtonBar just use the Button objects provided by you?
> Let's just say that's not the way it was designed to work. There are
> complications with using user-supplied Button objects. The ButtonBar
> -- or any NavBar-based component, for that matter -- needs tighter
> control over its child objects. Maybe Flex could get this to work
> well, but it was complicated back when it was being considered (not to
> mention somewhat inconsistent with the component's design).
>
> By design, the data provider should be just that -- a data provider.
>
> Throwing an error for objects of type DisplayObject is more of a
> "saving developers from shooting themselves in the foot" type of
> thing, which personally I'm no big fan of, but that's just the way it
> is now.

Thanks for your explanation!

It's unfortunate that it is prevented though, as my goal was to
selectively display ViewStack children buttons (instead of a mere
ViewStack binding that displays buttons for each child), i.e.:





  


I wanted my button bar not to show the "form button".

For your reference, I'm wrapping "chart" & "grid" components into
buttons.dataProvider:

buttons.dataProvider = [ {target: chart, icon: chart.icon},
{target: grid, icon: grid.icon} ]; // wrap to prevent DisplayObject
checking

and in my ItemClickEvent listener:

vs.selectedIndex = vs.getChildIndex(event.item.target); // unwrap
through the "target" property from above

My first thought was that it is cumbersome to do that wrap/unwrap,
thus my email. Seems that it can't be helped if that's the way it has
been designed.
Is there a better way?

Thanks,

Regards
-- 
Fiouz


Re: [flexcoders] ColdFusion Structures in Flex

2008-05-17 Thread Jeffry Houser


A structure in CF should turn into a Generic object in Flex (AS3).  
Have you checked documentation, I'm sure there is a data type map 
somewhere.  It took me less than 5 minutes to find this page 
http://livedocs.adobe.com/coldfusion/8/htmldocs/UseFlexDataService_10.html .


Yes, create a Value Object CFC and a Value Object AS3 Class.  Alias 
them appropriately.  The return type from your CFC Method will be the 
name of the class.


If you want to know how dataProviders work, open up the framework code 
and take a look. 



Dan Vega wrote:


I am new to Flex and I have some questions about data types. I have a 
method in ColdFusion that returns a structure. I heard that this is 
automatically converted for me. I was wondering if anyone can point me 
to article that explains what types in CF are converted to in Flex. I 
put a break point on my result and it just looks like an object.


A follow up to that is there a method that I can use that will return 
the type of object I am working with?


-
Completely separate how does the data provider for different 
components such as the tree and datagrid work?  I  have datagrids 
working with arraycollections and xmlcollections. Is there a specific 
format for the dp to work?




Thank You
Dan 

 


--
Jeffry Houser
Flex, ColdFusion, AIR
AIM: Reboog711  | Phone: 1-203-379-0773
--
Adobe Community Expert 

My Company:  
My Podcast: 
My Blog:  



Re: [flexcoders] ColdFusion Structures in Flex

2008-05-17 Thread Dan Vega
Here is what I am trying to do and it may make more sense. I have an object
coming back from ColdFusion that contains a list of datasource names. When
reading through the docs I can tell i need an arrayCollection or
XmlLIstCollection to use as the data provider.

I also need to list the field names for each datasource underneath that so
should I just build that completely on the cf side before passing it back or
when the datasource + is clicked retrieve a list of field names.



http://www.adobe.com/2006/mxml"; layout="absolute"
creationComplete="init()">
























[flexcoders] Re: Dispatching an event from an inline itemrenderer

2008-05-17 Thread jeffreyr6915
Hi Tracy,

I tried to remove as much code as possible. Thanks


DailyUpdateView.mxml
---

public function initApp():void
{ 

//Event Listener
currentStickyNote.addEventListener("taskUpdate",currentStickyViewHandler);

}


private function currentStickyViewHandler(event:UpdateScrumTaskEvent):void
{
currentStickyNote.category = event.category;
}






http://www.adobe.com/2006/mxml";
horizontalScrollPolicy="off" verticalScrollPolicy="off"  
mouseOver="showLargeSticky()">
   













UpdateScrumTaskEvent
-
package com.intuit.scrum.events
{
import flash.events.Event;

public class UpdateScrumTaskEvent extends Event
{

public var category:String;
public var description:String;
public var developer:String;
public var developerHrs:int;
public var qa:String;
public var qaHrs:int;
public var priority:int;

public function UpdateScrumTaskEvent(type:String,category:String,
description:String,

developer:String,developerHrs:int,qa:String,qaHrs:int,priority:int)
{
super(type);
this.category = category;
this.description = description;
this.developer = developer;
this.developerHrs = developerHrs;
this.qa = qa;
this.qaHrs = qaHrs;
this.priority = priority;
}

}
}






[flexcoders] TabNavigator children

2008-05-17 Thread Daniel
Hey guys,

Maybe this is easy, but I just can't figure it out! I have a
TabNavigator with a few tabs. At some point at run time I want to
dispose the TabNavigator and draw the containers in its tabs. The
problem is when I get the TabNavigator children and draw them on
screen it draws only one tab (the tab is selected by the time). The
unselected tabs exist, but are not drawn on screen. I've tried to
explicitly setting the position and size of each of them without success.

How can I draw all the tabs?



Re: [flexcoders] ColdFusion Structures in Flex

2008-05-17 Thread Mike Chabot
Dan,
If you have CF8, Google for "__type__" That is the key that does the
automatic conversion of a structure into a typed object. This shows
and example:
http://livedocs.adobe.com/coldfusion/8/htmldocs/UseFlexDataService_05.html
It is easy to implement and it works well.

For the data type conversion check this out:
http://livedocs.adobe.com/flashremoting/mx/Using_Flash_Remoting_MX/UseASData4.htm
It is old, but it should be accurate.

Good luck,
Mike Chabot

On Sat, May 17, 2008 at 11:36 AM, Dan Vega <[EMAIL PROTECTED]> wrote:
> I am new to Flex and I have some questions about data types. I have a method
> in ColdFusion that returns a structure. I heard that this is automatically
> converted for me. I was wondering if anyone can point me to article that
> explains what types in CF are converted to in Flex. I put a break point on
> my result and it just looks like an object.
>
> A follow up to that is there a method that I can use that will return the
> type of object I am working with?
>
> -
> Completely separate how does the data provider for different components such
> as the tree and datagrid work?  I  have datagrids working with
> arraycollections and xmlcollections. Is there a specific format for the dp
> to work?
>
>
>
> Thank You
> Dan
>
> 


[flexcoders] Changing parents throught Drag & Drop

2008-05-17 Thread Daniel
Hey guys,

Here's the scenario... I have a list of things displayed in a Tree.
You can drag one of them, and drop it in a Container. The Container is
in charge of creating what the dragged object specifies, generally an
UIComponent.  If the object is dropped inside a Container, it
succesfully sets the right parent for the object. Once the component
is created, it can still be dragged around. The problem is, once i've
created the object and the parent has been set, if the object is
dropped on other Container the parent property doesn't change, it's
always dropped on the Container it was initially dropped.

Every Container object has dragEnter and dragDrop handlers. The drag &
drop is done using the DragManager.

Why can't I change parents on drag & drop?



Re: [flexcoders] Why would mx.controls.NavBar.dataProvider not accept an array of DisplayObject? (3.0.0)

2008-05-17 Thread Manish Jethani
On 5/16/08, Fiouz <[EMAIL PROTECTED]> wrote:

> I'd like to specify a custom Array dataProvider to a
> mx.controls.ButtonBar instead of binding it to a ViewStack instance.
> I'm doing the following:
>
>var array:Array = new Array();
>array.push(chart); // chart is a DisplayObject instance
>array.push(grid); // grid is a DisplayObject too
>buttons.dataProvider = array;
>
> ... but NavBar.dataProvider (ButtonBar extends NavBar) doesn't seem to
> like this array of DisplayObject and throws an error, as seen in
> NavBar source code: (Flex 3.0.0)

[snip code]

> What is the reason behind throwing an error when an array of
> DisplayObject is given? Why would I have to wrap my DisplayObject
> instances in order to prevent this error?

The idea was to prevent you from doing this:

  


  

If the above were allowed, you'd think that your click handler would
get called, but in fact the ButtonBar (which is based on NavBar) would
actually be using the array as a data provider to create its own
Button objects; thus, your Button objects wouldn't get used as
children of the ButtonBar, they would just serve as data objects.

So, why not the ButtonBar just use the Button objects provided by you?
Let's just say that's not the way it was designed to work. There are
complications with using user-supplied Button objects. The ButtonBar
-- or any NavBar-based component, for that matter -- needs tighter
control over its child objects. Maybe Flex could get this to work
well, but it was complicated back when it was being considered (not to
mention somewhat inconsistent with the component's design).

By design, the data provider should be just that -- a data provider.

Throwing an error for objects of type DisplayObject is more of a
"saving developers from shooting themselves in the foot" type of
thing, which personally I'm no big fan of, but that's just the way it
is now.


Re: [flexcoders] bug in setMonth() method?

2008-05-17 Thread jeff
On Fri, May 16, 2008 at 11:10:21PM -0700, Alex Harui wrote:

> I would not guarantee results if you set values that are out of range.

Flex seems targeted to the business world and we need all the date-management 
help we can 
get.  Every aspect of parsing, validation, and math that you can think of will 
save us 
time and agony.


-Jeff


Re: [flexcoders] Re: a simple question of BitmapData

2008-05-17 Thread Frederico Garcia
flexawesome escreveu:
> thanks for reply,
>
> but I don't know how to use in my file, any example?
>
> thanks
>
> --- In flexcoders@yahoogroups.com, Frederico Garcia <[EMAIL PROTECTED]> 
> wrote:
>   
>> flexawesome escreveu:
>> 
>>> Hi there,
>>>
>>> do you know how can I use it to duplicate the image? It seems 
>>>   
> doesn't 
>   
>>> work. any ideas?
>>>
>>> Thank you
>>>
>>> loader = new SWFLoader();
>>> loader.addEventListener(Event.COMPLETE, Bitmapdata) 
>>>   
>   
>   
>>> 
>>> loader.source 
>>>   
> = "http://us.i1.yimg.com/us.yimg.com/i/us/nt/ma/ma_tech-
>   
>>> grp_1.gif"
>>> //addChild(loader);
>>>
>>>
>>> private function oBitmapdata(e:Event):void
>>> {
>>> 
>>> var img:Image = new Image();
>>> var data:BitmapData = Bitmap(loader.content).bitmapData;
>>> var bitmap:Bitmap = new Bitmap(data);
>>> 
>>> img.addChild(bitmap)
>>> 
>>> addChild(img);
>>>
>>> }
>>>
>>>
>>> 
>>>
>>> --
>>> Flexcoders Mailing List
>>> FAQ: 
>>>   
> http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
>   
>>> Search Archives: http://www.mail-archive.com/flexcoders%
>>>   
> 40yahoogroups.comYahoo! Groups Links
>   
>>>
>>>
>>> __ NOD32 3106 (20080516) Information __
>>>
>>> This message was checked by NOD32 antivirus system.
>>> http://www.eset.com
>>>
>>>
>>>
>>>   
>>>   
>> Hi,
>>
>> you can use this method:
>>
>> public static function clone(value:ByteArray):ByteArray {
>> var myBA:ByteArray = new ByteArray();
>> myBA.writeObject(value);
>> myBA.position = 0;
>>
>> return myBA.readObject();
>> }
>>
>> kind regards,
>>
>> Frederico Garcia
>>
>> 
>
>
>
> 
>
> --
> Flexcoders Mailing List
> FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
> Search Archives: 
> http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! Groups Links
>
>
>
>
> __ NOD32 3106 (20080516) Information __
>
> This message was checked by NOD32 antivirus system.
> http://www.eset.com
>
>
>
>   
Sorry, there's an easier way. BitmapData already implements clone(). 
Here's an example from the Flex Language Reference:

import flash.display.Bitmap;
import flash.display.BitmapData;

var bmd1:BitmapData = new BitmapData(100, 80, false, 0x);
var bmd2:BitmapData = bmd1.clone();

bmd1.setPixel32(1, 1, 0x);

trace(bmd1.getPixel32(1, 1).toString(16)); // 
trace(bmd2.getPixel32(1, 1).toString(16)); // ff00

var bm1:Bitmap = new Bitmap(bmd1);
this.addChild(bm1);

var bm2:Bitmap = new Bitmap(bmd2);
bm2.x = 110;

this.addChild(bm2);


Hope this helps you.

Frederico Garcia


[flexcoders] ColdFusion Structures in Flex

2008-05-17 Thread Dan Vega
I am new to Flex and I have some questions about data types. I have a method
in ColdFusion that returns a structure. I heard that this is automatically
converted for me. I was wondering if anyone can point me to article that
explains what types in CF are converted to in Flex. I put a break point on
my result and it just looks like an object.

A follow up to that is there a method that I can use that will return the
type of object I am working with?

-
Completely separate how does the data provider for different components such
as the tree and datagrid work?  I  have datagrids working with
arraycollections and xmlcollections. Is there a specific format for the dp
to work?



Thank You
Dan


[flexcoders] Re: a simple question of BitmapData

2008-05-17 Thread flexawesome
thanks for reply,

but I don't know how to use in my file, any example?

thanks

--- In flexcoders@yahoogroups.com, Frederico Garcia <[EMAIL PROTECTED]> 
wrote:
>
> flexawesome escreveu:
> > Hi there,
> >
> > do you know how can I use it to duplicate the image? It seems 
doesn't 
> > work. any ideas?
> >
> > Thank you
> >
> > loader = new SWFLoader();
> > loader.addEventListener(Event.COMPLETE, Bitmapdata) 

> > 
> > loader.source 
= "http://us.i1.yimg.com/us.yimg.com/i/us/nt/ma/ma_tech-
> > grp_1.gif"
> > //addChild(loader);
> >
> >
> > private function oBitmapdata(e:Event):void
> > {
> > 
> > var img:Image = new Image();
> > var data:BitmapData = Bitmap(loader.content).bitmapData;
> > var bitmap:Bitmap = new Bitmap(data);
> > 
> > img.addChild(bitmap)
> > 
> > addChild(img);
> >
> > }
> >
> >
> > 
> >
> > --
> > Flexcoders Mailing List
> > FAQ: 
http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
> > Search Archives: http://www.mail-archive.com/flexcoders%
40yahoogroups.comYahoo! Groups Links
> >
> >
> >
> >
> > __ NOD32 3106 (20080516) Information __
> >
> > This message was checked by NOD32 antivirus system.
> > http://www.eset.com
> >
> >
> >
> >   
> Hi,
> 
> you can use this method:
> 
> public static function clone(value:ByteArray):ByteArray {
> var myBA:ByteArray = new ByteArray();
> myBA.writeObject(value);
> myBA.position = 0;
>
> return myBA.readObject();
> }
> 
> kind regards,
> 
> Frederico Garcia
>




Re: [flexcoders] a simple question of BitmapData

2008-05-17 Thread Frederico Garcia
flexawesome escreveu:
> Hi there,
>
> do you know how can I use it to duplicate the image? It seems doesn't 
> work. any ideas?
>
> Thank you
>
> loader = new SWFLoader();
> loader.addEventListener(Event.COMPLETE, Bitmapdata)   
>   
> loader.source = "http://us.i1.yimg.com/us.yimg.com/i/us/nt/ma/ma_tech-
> grp_1.gif"
> //addChild(loader);
>
>
> private function oBitmapdata(e:Event):void
> {
>   
>   var img:Image = new Image();
>   var data:BitmapData = Bitmap(loader.content).bitmapData;
>   var bitmap:Bitmap = new Bitmap(data);
>   
>   img.addChild(bitmap)
>   
>   addChild(img);
>
> }
>
>
> 
>
> --
> Flexcoders Mailing List
> FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
> Search Archives: 
> http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! Groups Links
>
>
>
>
> __ NOD32 3106 (20080516) Information __
>
> This message was checked by NOD32 antivirus system.
> http://www.eset.com
>
>
>
>   
Hi,

you can use this method:

public static function clone(value:ByteArray):ByteArray {
var myBA:ByteArray = new ByteArray();
myBA.writeObject(value);
myBA.position = 0;
   
return myBA.readObject();
}

kind regards,

Frederico Garcia


[flexcoders] a simple question of BitmapData

2008-05-17 Thread flexawesome
Hi there,

do you know how can I use it to duplicate the image? It seems doesn't 
work. any ideas?

Thank you

loader = new SWFLoader();
loader.addEventListener(Event.COMPLETE, Bitmapdata) 

loader.source = "http://us.i1.yimg.com/us.yimg.com/i/us/nt/ma/ma_tech-
grp_1.gif"
//addChild(loader);


private function oBitmapdata(e:Event):void
{

var img:Image = new Image();
var data:BitmapData = Bitmap(loader.content).bitmapData;
var bitmap:Bitmap = new Bitmap(data);

img.addChild(bitmap)

addChild(img);

}



[flexcoders] Re: bug in setMonth() method?

2008-05-17 Thread Amy
--- In flexcoders@yahoogroups.com, "Alex Harui" <[EMAIL PROTECTED]> wrote:
>
> I would not guarantee results if you set values that are out of range.

So you think that it's ok to fail silently and return a nearly 
appropriate value rather than throwing an error?



RE: [flexcoders] Re: How to tell if variable is an int, uint, or a Number?

2008-05-17 Thread Glenn Williams
A little off topic I know but I really hope that at some point the Flash
Player extends it number handling to include byte, word, long etc. I hate
using int or uint when I know I really just need a byte or whatever.

 

It just pains me.

 

I suppose that's due to my machine code background, but it always feels so
wasteful.

 

Glenn Williams

tinylion development UK

 

 

www.flex-ria.com

www.tinylion.co.uk

 

 

From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of EECOLOR
Sent: Saturday, May 17, 2008 11:51 AM
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] Re: How to tell if variable is an int, uint, or a
Number?

 

I would recommend you to use the getQualifiedClassName method, it is a bit
less expensive than the describeType method.


Greetz Erik



On 5/16/08, Paul Whitelock <[EMAIL PROTECTED]> wrote:

Alrighty then, I filed a bug report since the following outputs "int":

var uintVar:uint = 5; trace(describeType(uintVar)[EMAIL PROTECTED]());

--- In flexcoders@yahoogroups.com  ,
"Gordon Smith" <[EMAIL PROTECTED]> wrote:
>
> I think there is a conceptual distinction between the runtime type of an
> AS3 value and the compile-time type of a var or parameter that holds
> such a value.
> 
> 
> 
> The 'is' operator works on values. A value like 5 'is' both an int, a
> uint, and a Number because it is a legal value in the set of possible
> values for each of these types.
> 
> 
> 
> But I would expect a var declared as
> 
> 
> 
> var u:uint;
> 
> 
> 
> to report itself via describeType() as a uint, just like int and Number
> do. It seems like a bug that it doesn't.
> 
> 
> 
> Gordon Smith
> 
> Adobe Flex SDK Team
> 
> 
>

 

 



Glenn Williams.vcf
Description: Binary data


[flexcoders] DateChooser setting displayedMonth, displayedYear does nothing

2008-05-17 Thread rleuthold
Hi,

I have a DateChooser in a popUp window.  If I set the displayedMonth and 
displayedYear 
properties on that DateChooser (after creating the popup), nothing happens. The 
display is 
still on the  month and year previously selected/displayed. Does anybody have 
an idea ?

code (parent comp):

_datePickerWin = 
DateRangerPopUp(PopUpManager.createPopUp(Application.application as 
DisplayObject, DateRangerPopUp, true));
_datePickerWin.compDateRange = _dateRange;

code (DateRangerPopup):
public function set compDateRange(dateRange:Array):void
{
_compDateRange = dateRange;

  dateChooser.selectedRanges = [ {rangeStart: _compDateRange[0], 
rangeEnd: 
_compDateRange[1] }];

dateChooser.displayedMonth = _compDateRange[1].month;
dateChooser.displayedYear =  _compDateRange[1].fullYear;


Thank's rico



[flexcoders] XMLListCollection as dataProvider for ToggleButtonBar problem

2008-05-17 Thread Ernesto Casasín
Hi all,

I'm trying to populate a ToggleButtonBar component with data hold on  
a XMLListCollection, but it throws an error

TypeError: Error #1034: Error cannot convert  
mx.collections::[EMAIL PROTECTED] in mx.containers.ViewStack.
at mx.controls::NavBar/_setTargetViewStack()[E:\dev\3.0.x\frameworks 
\projects\framework\src\mx\controls\NavBar.as:963]
at mx.controls::NavBar/checkPendingTargetStack()[E:\dev\3.0.x 
\frameworks\projects\framework\src\mx\controls\NavBar.as:1049]
at mx.controls::NavBar/commitProperties()[E:\dev\3.0.x\frameworks 
\projects\framework\src\mx\controls\NavBar.as:672]
at mx.controls::ButtonBar/commitProperties()[E:\dev\3.0.x\frameworks 
\projects\framework\src\mx\controls\ButtonBar.as:501]
at mx.controls::ToggleButtonBar/commitProperties()[E:\dev\3.0.x 
\frameworks\projects\framework\src\mx\controls\ToggleButtonBar.as:328]
at mx.core::UIComponent/validateProperties()[E:\dev\3.0.x\frameworks 
\projects\framework\src\mx\core\UIComponent.as:5670]
at mx.managers::LayoutManager/validateProperties()[E:\dev\3.0.x 
\frameworks\projects\framework\src\mx\managers\LayoutManager.as:519]
at mx.managers::LayoutManager/doPhasedInstantiation()[E:\dev\3.0.x 
\frameworks\projects\framework\src\mx\managers\LayoutManager.as:669]
at Function/http://adobe.com/AS3/2006/builtin::apply()
at mx.core::UIComponent/callLaterDispatcher2()[E:\dev\3.0.x 
\frameworks\projects\framework\src\mx\core\UIComponent.as:8460]
at mx.core::UIComponent/callLaterDispatcher()[E:\dev\3.0.x\frameworks 
\projects\framework\src\mx\core\UIComponent.as:8403]

is it possible?

TIA

––
Ernesto Casasín
Abaco Digital, SL
José Pardo Sastrón, 7, 1
50001 Zaragoza
Tel: 34 976 29 79 80
Fax: 34 976 20 48 50






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

<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/flexcoders/

<*> Your email settings:
Individual Email | Traditional

<*> To change settings online go to:
http://groups.yahoo.com/group/flexcoders/join
(Yahoo! ID required)

<*> To change settings via email:
mailto:[EMAIL PROTECTED] 
mailto:[EMAIL PROTECTED]

<*> To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/



Re: [flexcoders] Re: How to tell if variable is an int, uint, or a Number?

2008-05-17 Thread EECOLOR
I would recommend you to use the getQualifiedClassName method, it is a bit
less expensive than the describeType method.


Greetz Erik


On 5/16/08, Paul Whitelock <[EMAIL PROTECTED]> wrote:
>
> Alrighty then, I filed a bug report since the following outputs "int":
>
> var uintVar:uint = 5; trace(describeType(uintVar)[EMAIL PROTECTED]());
>
> --- In flexcoders@yahoogroups.com , "Gordon
> Smith" <[EMAIL PROTECTED]> wrote:
> >
> > I think there is a conceptual distinction between the runtime type of an
> > AS3 value and the compile-time type of a var or parameter that holds
> > such a value.
> >
> >
> >
> > The 'is' operator works on values. A value like 5 'is' both an int, a
> > uint, and a Number because it is a legal value in the set of possible
> > values for each of these types.
> >
> >
> >
> > But I would expect a var declared as
> >
> >
> >
> > var u:uint;
> >
> >
> >
> > to report itself via describeType() as a uint, just like int and Number
> > do. It seems like a bug that it doesn't.
> >
> >
> >
> > Gordon Smith
> >
> > Adobe Flex SDK Team
> >
> >
> >
>