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

Associating simple data with a component shouldn't be this hard!

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Later
    • Adobe Flex SDK 3.3 (Release)
    • None
    • mx: General
    • None
    • Affected OS(s): All OS Platforms
      Affected OS(s): All OS Platforms
      Language Found: English

    Description

      I think it's a major oversight that it is not simple to associate some simple data with most controls (for example, a button). Visual Basic (That's right, I said it... Visual Basic!) got this right, why can't Flex? In VB, there was a "tag" property on just about every component, which was never used by anything except what the developer uses it for. It is just a way to store some data (say, an Id value) that is associated with a component (say, a button). In Flex, the label property of said button is being used for the display value, so there's no logical location for an Id or other associated value.

      Workaround (if any):

      The only solution is to create a new component that extends the desired component, and adds some property to store the value. What a pain! Something that should take 2 seconds to store now takes an extra 10 minutes (the first time) and an extra component/class to keep track of. Seems very wasteful to me, when ideally a quick change could be made to the UIComponent class (or similar) to add a property that a majority of components would inherit.

      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: