flex-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Justin Mclean (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (FLEX-34011) Axis Render throws RTE when axis is null
Date Mon, 23 Dec 2013 22:13:50 GMT

     [ https://issues.apache.org/jira/browse/FLEX-34011?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Justin Mclean updated FLEX-34011:
---------------------------------

    Labels: chart easyfix easytest  (was: chart quick_to_fix)

> Axis Render throws RTE when axis is null
> ----------------------------------------
>
>                 Key: FLEX-34011
>                 URL: https://issues.apache.org/jira/browse/FLEX-34011
>             Project: Apache Flex
>          Issue Type: Bug
>          Components: Charts
>    Affects Versions: Apache Flex 4.11.0
>         Environment: Any
>            Reporter: João Fernandes
>            Priority: Minor
>              Labels: chart, easyfix, easytest
>   Original Estimate: 0.5h
>  Remaining Estimate: 0.5h
>
> When a CartesianChart is initialized with a null Axis, which can be created in the future
an propagated through bindings, the chart throws RTE because the value is not validated if
it's null or not.
> In AxisRenderer, 
>    public function set axis(value:IAxis):void
>     {
>         if (_axis)
>         {
>             _axis.removeEventListener("axisChange", axisChangeHandler, false);
>             _axis.removeEventListener("titleChange", titleChangeHandler, false);
>         }
>         _axis = value;
>         value.addEventListener("axisChange", axisChangeHandler,
>                                false, 0, true);
>         value.addEventListener("titleChange", titleChangeHandler,
>                                false, 0, true);
>     }
> should be 
>    public function set axis(value:IAxis):void
>     {
>         if (_axis)
>         {
>             _axis.removeEventListener("axisChange", axisChangeHandler, false);
>             _axis.removeEventListener("titleChange", titleChangeHandler, false);
>         }
>         _axis = value;
>        if(value)
>        {
>         value.addEventListener("axisChange", axisChangeHandler,
>                                false, 0, true);
>         value.addEventListener("titleChange", titleChangeHandler,
>                                false, 0, true);
>        }
>     }



--
This message was sent by Atlassian JIRA
(v6.1.5#6160)

Mime
View raw message