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

RTE reparenting item after SVN 19911

    XMLWordPrintableJSON

Details

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

    Description

      Steps to reproduce:
      1. Compile & run:
      <mx:Application width="800" height="600" backgroundColor="0xffffff"
      xmlns:fx="http://ns.adobe.com/mxml/2009" xmlns:mx="library://ns.adobe.com/flex/mx" xmlns:s="library://ns.adobe.com/flex/spark"
      xmlns:filters="flash.filters.*"
      >

      <fx:Script>
      <![CDATA[
      import mx.collections.ArrayCollection;
      import mx.core.Container;
      import mx.core.UIComponent;
      import mx.events.StateChangeEvent;

      ]]
      >
      </fx:Script>

      <mx:states>
      <!-- Base default state -->
      <mx:State name="defaultState" />

      <!-- Test states -->

      <mx:State name="state176" />
      <mx:State name="state180" />
      </mx:states>

      <mx:Button click="currentState='state176'" label="Set state"/>

      <!--
      ================================================================================
      Reparenting
      ================================================================================
      -->
      <mx:Box id="bx01" borderColor="0x000000" borderStyle="solid" >
      <mx:Button id="btn049" excludeFrom="state176" />
      </mx:Box>
      <fx:Reparent target="btn049" includeIn="state176" />

      <mx:TabNavigator id="tabNav02">
      <mx:Box id="bx06" excludeFrom="state180">
      </mx:Box>
      </mx:TabNavigator>

      <fx:Reparent target="bx06" includeIn="state180" />
      </mx:Application>
      2. Click Set State button

      Actual Results:
      [SWF] C:\Users\jchuang\01242011Workspace\statesFailure\bin-debug\statesFailure.swf - 1,251,149 bytes after decompression
      RangeError: Error #2006: The supplied index is out of bounds.
      atflash.display::DisplayObjectContainer/getChildAt()
      atmx.core::Container/getChildAt()[E:\dev\hero_private\frameworks\projects\mx\src\mx\core\Container.as:2741]
      atmx.controls::ToggleButtonBar/hiliteSelectedNavItem()[E:\dev\hero_private\frameworks\projects\mx\src\mx\controls\ToggleButtonBar.as:470]
      atmx.controls::NavBar/changeHandler()[E:\dev\hero_private\frameworks\projects\mx\src\mx\controls\NavBar.as:1232]
      atflash.events::EventDispatcher/dispatchEventFunction()
      atflash.events::EventDispatcher/dispatchEvent()
      atmx.core::UIComponent/dispatchEvent()[E:\dev\hero_private\frameworks\projects\framework\src\mx\core\UIComponent.as:13094]
      atmx.containers::ViewStack/set selectedIndex()[E:\dev\hero_private\frameworks\projects\mx\src\mx\containers\ViewStack.as:722]
      atmx.containers::ViewStack/childRemoveHandler()[E:\dev\hero_private\frameworks\projects\mx\src\mx\containers\ViewStack.as:1409]
      atmx.containers::ViewStack/removeChild()[E:\dev\hero_private\frameworks\projects\mx\src\mx\containers\ViewStack.as:1450]
      atmx.core::Container/removeChildAt()[E:\dev\hero_private\frameworks\projects\mx\src\mx\core\Container.as:2709]
      atmx.core::Container/removeElementAt()[E:\dev\hero_private\frameworks\projects\mx\src\mx\core\Container.as:3026]
      atmx.states::AddItems/remove()[E:\dev\hero_private\frameworks\projects\framework\src\mx\states\AddItems.as:634]
      atmx.core::UIComponent/removeState()[E:\dev\hero_private\frameworks\projects\framework\src\mx\core\UIComponent.as:10679]
      atmx.core::UIComponent/commitCurrentState()[E:\dev\hero_private\frameworks\projects\framework\src\mx\core\UIComponent.as:10441]
      atmx.core::UIComponent/setCurrentState()[E:\dev\hero_private\frameworks\projects\framework\src\mx\core\UIComponent.as:10296]
      atmx.core::UIComponent/set currentState()[E:\dev\hero_private\frameworks\projects\framework\src\mx\core\UIComponent.as:6406]
      atstatesFailure/___statesFailure_Button2_click()[C:\Users\jchuang\01242011Workspace\statesFailure\src\statesFailure.mxml:129]

      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: