Uploaded image for project: 'Apache Flex'
  1. Apache Flex
  2. FLEX-18929

Cannot set newly defined properties in MXML subclass

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Later
    • Adobe Flex SDK Previous
    • None
    • None
    • Affected OS(s): All OS Platforms
      Language Found: English

    Description

      Steps to reproduce:
      1. Create a new MXML file with the following code:

      <?xml version="1.0" encoding="utf-8"?>
      <s:Group xmlns:fx="http://ns.adobe.com/mxml/2009" xmlns:s="library://ns.adobe.com/flex/spark" myNewProperty="blah">
      <fx:Script>
      <![CDATA[
      public var myNewProperty:String;
      ]]
      >
      </fx:Script>
      </s:Group>

      Actual Results:
      Cannot resolve attribute 'myNewProperty' for component type spark.components.Group.

      Expected Results:
      The "myNewProperty" is defined on the subclass and we should be allowed to set it here. This also happens for setters as well.

      Workaround (if any):
      Don't set the property in MXML, but create a function to do this and call it during a lifecycle event (creationComplete or something like that). However, when doing binding, it sucks to have to call BindingUtil, but that will still work as a work-around.

      Attachments

        Activity

          People

            adobejira Adobe JIRA
            adobejira Adobe JIRA
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: