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

RTE adding a component to ItemsComponent with addItem

    XMLWordPrintableJSON

Details

    Description

      Steps to reproduce:
      1. Run the following:
      <?xml version="1.0" encoding="utf-8"?>
      <Application xmlns="http://ns.adobe.com/mxml/2009"
      xmlns:mx="library:adobe/flex/halo" initialize="init()"
      >
      <layout>
      <VerticalLayout />
      </layout>

      <Script>
      <![CDATA[
      import flex.component.Button;

      private var btn:Button;

      private function init():void

      { btn = new Button(); pnl.addItem(btn); }

      ]]
      >
      </Script>

      <ItemsComponent id="pnl">
      <Button />
      </ItemsComponent>

      </Application>

      Actual Results:
      Main Thread (Suspended: ArgumentError: Error #2025: The supplied DisplayObject must be a child of the caller.)
      flash.display::DisplayObjectContainer/removeChild [no source]
      mx.core::UIComponent/http://www.adobe.com/2006/flex/mx/internal::$removeChild
      mx.core::UIComponent/removeChild
      flex.core::Group/itemRemoved
      flex.core::Group/removeItemAt
      flex.component::ItemsComponent/partAdded
      flex.core::SkinnableComponent/findSkinParts
      flex.core::SkinnableComponent/loadSkin
      flex.core::SkinnableComponent/commitProperties
      mx.core::UIComponent/validateProperties
      mx.managers::LayoutManager/validateProperties
      mx.managers::LayoutManager/doPhasedInstantiation
      Function/http://adobe.com/AS3/2006/builtin::apply [no source]
      mx.core::UIComponent/callLaterDispatcher2
      mx.core::UIComponent/callLaterDispatcher

      Expected Results:
      No RTE

      Workaround (if any):

      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: