thanksmister/as3scrollinglist — Issue #2: removeListItem()
Author: derekobrien
Created: 2011-11-24 13:31:12+00:00
State: open

Using your demo and adding removeListItem(index) to your handler for the current selected item gives the following error:

[SWF] AS3ScrollingList.swf - 14808 bytes after decompression
List item selected: 9
destroy
destroy
Error: Error #2094: Event dispatch recursion overflow.
at flash.display::DisplayObjectContainer/removeChild()
at com.thanksmister.touchlist.renderers::TouchListItemRenderer/destroy()[/Users/XXXX/Documents/GitHub/as3scrollinglist/com/thanksmister/touchlist/renderers/TouchListItemRenderer.as:174]
at flash.display::DisplayObjectContainer/removeChild()
at com.thanksmister.touchlist.renderers::TouchListItemRenderer/destroy()[/Users/XXXX/Documents/GitHub/as3scrollinglist/com/thanksmister/touchlist/renderers/TouchListItemRenderer.as:174]
at flash.display::DisplayObjectContainer/removeChildAt()
at com.thanksmister.touchlist.controls::TouchList/removeListItem()[/Users/XXXX/Documents/GitHub/as3scrollinglist/com/thanksmister/touchlist/controls/TouchList.as:195]
at AS3ScrollingList/handlelistItemSelected()[/Users/XXXX/Documents/GitHub/as3scrollinglist/AS3ScrollingList.as:133]
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at com.thanksmister.touchlist.controls::TouchList/handleItemSelected()[/Users/XXXX/Documents/GitHub/as3scrollinglist/com/thanksmister/touchlist/controls/TouchList.as:409]
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at com.thanksmister.touchlist.renderers::TouchListItemRenderer/selectHandler()[/Users/XXXX/Documents/GitHub/as3scrollinglist/com/thanksmister/touchlist/renderers/TouchListItemRenderer.as:201]

(REPEATS)