flex-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alex Harui <aha...@adobe.com>
Subject Re: SystemManager seems to call addChildAt > out of bounds
Date Wed, 18 Sep 2013 23:57:26 GMT
On 9/18/13 2:49 PM, "Jiem" <jeanmichel.vilain@gmail.com> wrote:

>Thank you, indeed it should be a UIComponent and a Group. I fixed that.
>issue still occurs. I really need a solution to this and have no other
>What else do you think could cause this out of index crash?
Lots of things.  Is the stack trace exactly the same?  If so, that would
imply a Menu is still being added as a child.  Otherwise, post the new
stack trace.

>Alex Harui wrote
>> It looks like the code calls addElement() passing in the menu.  I don't
>> believe Menu is designed to be a child component, only a popup.
>> -Alex
>> On 9/12/13 7:52 PM, "Jiem" &lt;
>> jeanmichel.vilain@
>> &gt; wrote:
>>>I'm working to a project since a long time, I did recently shifted from
>>>to Apache Flex 10.
>>>I got this issue and it seems to happen in a non deterministic fashion.
>>>I can trigger it in several different ways, the 2 last calls only are
>>>same every time (System Manager:2130 and SystemManager:1753). It's like
>>>something gets broken and then the next time I use the PopUpManager, it
>>>I'm starting to believe this is a bug inside Apache Flex, it's been
>>>this bug is around, it's very hard to reproduce and I have no step-to.
>>>RangeError: Error #2006: The supplied index is out of bounds.
>>>	at flash.display::DisplayObjectContainer/addChildAt()
>>>	at
>>>	at
>>>	at
>>>	at
>>>	at
>>>	at
>>>	at
>>>	at
>>>This is the code that produced that error stack:
>>>private function openMenu():void {
>>>        if(_isMenuOpened)
>>>            return;
>>>        APPLICATION.youContainer.height = CONTAINER_HEIGHT_OPENED;
>>>        APPLICATION.opponentContainer.height = CONTAINER_HEIGHT_OPENED;
>>>        // rebuilding menuData
>>>        _menuData.removeAll();
>>>        if (_account != DATA_TABLE.you[0]) {
>>>            if (!_account.hasPrivateChatWithYou)
>>>                addMenuAction(resource_manager.getString("ui",
>>>"icard.startChat"), null,
>>>                        FrontController.startPrivateChat, _account,
>>>            if (!APPLICATION.opponentContainer.contains(this)) {
>>>                addMenuAction(resource_manager.getString("ui",
>>>"icard.gameInvite"), null, FRONT_CONTROLLER.gameInvite, this.data);
>>>                addMenuAction(resource_manager.getString("ui",
>>>"icard.tradeInvite"), null, FRONT_CONTROLLER.tradeInvite, this.data);
>>>            }
>>>        } else {
>>>            if (APPLICATION.youContainer.contains(this))
>>>                addMenuAction(resource_manager.getString("ui",
>>>"icard.signOut"), null, FRONT_CONTROLLER.closeConnection, null);
>>>            if (GAME != null)
>>>                addMenuAction(resource_manager.getString("ui",
>>>"icard.surrender"), null, GameComponent.surrender);
>>>        }
>>>        if 
>>>            addMenuAction(resource_manager.getString("ui",
>>>"icard.viewProfile"), null, FrontController.openProfileWindow,
>>>        // displaying
>>>        _menu.width = width;
>>>        _menu.show(0, MENU_OFFSET_Y);
>>>        menuContainer.addElement(_menu);
>>>        _isMenuOpened = true;
>>>    }
>>>And the _menu is created in a init() function, called only once, during
>>>component's creationComplete.
>>>        _menu = Menu.createMenu(menuContainer, _menuData, false);
>>>I'm extremely interested by clues regarding this issue. I'm running a
>>>test for Faƫria: Strategy Card Game, the game uses this code. It's a
>>>client/server architecture (AS3/Java), http://faeria.net.
>>>View this message in context:
>>>Sent from the Apache Flex Users mailing list archive at Nabble.com.
>View this message in context:
>Sent from the Apache Flex Users mailing list archive at Nabble.com.

View raw message