08-10-2010 03:31 PM
As you know, when we want disply a screen,
we use App.pushScreen and put screen into application stack.
what i am curious is if user popScreen, and that screen will never be used.
will it be garbage-collected?
1st: AScreen was pushed and displayed on top.
2ed: BScreen was pushed and displayed on top.
*as you know, AScreen is in stack, when BScreen was closed, it will always show AScreen.
3rd: CScreen was pushed and displayed on top.
In this case, User directly pushes AScreen to top from CScreen.
then application runs on background, and never user BScreen.
is BScreen always in applicaiton memory?
Do I need to garbage-collect BScreen explicit?
08-10-2010 05:52 PM
I think you will be better served with your question on the Java forums..
Would you like me to move it there?
08-11-2010 02:35 PM
In the scenario you have suggested, if B Screen is on the Display Stack, it will not be garbage collected.
I suspect you have a more complicated scenario in mind. Please fire away....
08-11-2010 04:51 PM
I'd appreiciate youir answer.
what about pop up dialog?
work mechanism of dialog sounds same as screen mechanism.
and about the scenrio that i posted, I want to garbage collect that BScreen, How to do it?
Keep Object handler and then set it to null?