flex-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Harbs (JIRA)" <j...@apache.org>
Subject [jira] [Created] (FLEX-35077) Missed case of XML assingment
Date Tue, 12 Apr 2016 20:04:25 GMT
Harbs created FLEX-35077:
----------------------------

             Summary: Missed case of XML assingment
                 Key: FLEX-35077
                 URL: https://issues.apache.org/jira/browse/FLEX-35077
             Project: Apache Flex
          Issue Type: Bug
          Components: FalconJX
            Reporter: Harbs


The last line of the following code:
{code:actionscript}
var svg:XML = <svg>
 <group>
   <rect id="1" />
   <rect id="2" />
 </group>
 <group>
   <rect id="3" />
   <rect id="4" />
 </group>
</svg>;

var rects:XMLList = svg..rect;
rects.(@id==3).@height = "100px";
{code}
compiles into:
{code:javascript}
rects.filter(function(node){return (node.attribute('id') == 3)}).attribute('height') = "100px";
{code}
It should have been:
{code:javascript}
rects.filter(function(node){return (node.attribute('id') == 3)}).setAttribute('height',"100px");
{code}



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

Mime
View raw message