[ 
https://issues.apache.org/jira/browse/FLEX-17210?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14558828#comment-14558828
 ] 

Chris Martin commented on FLEX-17210:
-------------------------------------

I'm under the same lines of thinking as Alex on this one.  This whole issue 
stemmed from a resource not being loaded when it was attempted to be used; 
thus, the formatting failed. The resolution was to make sure that the resource 
is loaded before attempting to use it. The resolution being, "not a problem". 
The SDK is behaving as expected because it's highly flexible. Even tests with 
the ResourceManager demonstrate this flexibility.

Maybe the original bug filer was just wanting the NumberFormatter to fail with 
more information?  Like at that point we log a trace warning saying that the 
requested resource has not been loaded up yet?  Since we are not throwing an 
exception we are not halting the execution of an application and yet we are 
informing the user as to why the NumberFormatter is not behaving in an expected 
manner.

> mx:NumberFormatter failed when use localeChain
> ----------------------------------------------
>
>                 Key: FLEX-17210
>                 URL: https://issues.apache.org/jira/browse/FLEX-17210
>             Project: Apache Flex
>          Issue Type: Bug
>          Components: Formatters
>    Affects Versions: Adobe Flex SDK Previous
>         Environment: Affected OS(s): Windows
> Affected OS(s): 
> Language Found: English
>            Reporter: Adobe JIRA
>            Assignee: Justin Mclean
>              Labels: easytest
>
>       Steps to reproduce:
> <?xml version="1.0" encoding="utf-8"?>
> <mx:WindowedApplication xmlns:mx="http://www.adobe.com/2006/mxml"; 
> layout="absolute" creationComplete="onCC();">
>       <mx:Script>
>               <![CDATA[
>                       import mx.formatters.NumberFormatter;
>               
>                       private function onCC():void
>                       {
>                               var nf:NumberFormatter = new NumberFormatter();
>                               nf.precision = 2;
>                               resourceManager.localeChain = ['zh-Hans'];      
>                         
>                               trace("number:"+nf.format(1/3));        
>                               resourceManager.localeChain = ['en_US'];
>                               trace("number:"+nf.format(1/3));        
>                       }
>               ]]
>       >
>       </mx:Script>
> </mx:WindowedApplication>
>  
>  Actual Results:
>  
> number:
> number:0.33
>  
>  Expected Results:
>  
> number:0.33
> number:0.33
>  
>  Workaround (if any):
>     



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to