Futurescale, Inc. PureMVC Home

The PureMVC Framework Code at the Speed of Thought


Over 10 years of community discussion and knowledge are maintained here as a read-only archive.

New discussions should be taken up in issues on the appropriate projects at https://github.com/PureMVC

Pages: [1]
Print
Author Topic: DisplayObject not being removed from memory getting Error #2025  (Read 3121 times)
jgervin
Courseware Beta
Sr. Member
***
Posts: 50


View Profile Email
« on: February 25, 2009, 09:28:43 »

So I have on my main Application page 3 components:

Graph: displaylist[0]
Menu: displaylist[1]
vslider: displaylist[2]

I am trying to create a popup (can't use popup manager because popup needs to be between Graph and Menu (see above).

So I am instantiating a component that looks like a callout on DisplayList[1] pushing everything else up. So far so good.  To create the callout you click on child objects of Graph the first time you click an object, creating a callout and its Mediator, it opens the callout. You can then close the callout, which also removes the Mediator. But when I click another node the first callout isn't deleted from memory so it tries to use that callout and that is when i get the #2025 error.

I have double checked that all references to the first callout are deleted or removed. Still I get the error?

Any suggestions?

TIA, J
Logged
puremvc
Global Moderator
Hero Member
*****
Posts: 2871



View Profile WWW Email
« Reply #1 on: February 26, 2009, 06:15:58 »

How do you remove the mediator for callout?

I'm imagining that inside the mediator for the callout you set an event listener on the callout to hear when it is removed from the stage and this is what causes its mediator to remove itself? Does the mediator also remove all event listeners it placed on the callout, null its reference to it before removing itself?

-=Cliff>
Logged
Pages: [1]
Print