Details
-
Bug
-
Status: Open
-
Major
-
Resolution: Unresolved
-
Adobe Flex SDK 3.5 (Release)
-
None
-
None
-
Affected OS(s): All OS Platforms
Affected OS(s): All OS Platforms
Language Found: English
Description
Steps to reproduce:
1.Dynamically created N RadioButtons inside GridRows/GridItems of a Grid myGrid
2.Call myGrid.removeAllChildren();
3.The radio buttons are still referenced in the automaticRadioButtonGroups, and won't be garbage collected
document.automaticRadioButtonGroups[groupName].radioButtons
Actual Results:
The radio buttons are not garbage collected
Expected Results:
The radio buttons must be garbage collected
Workaround (if any):
use an explicit RadioButtonGroup and clear it/ renew it manually after the removeAll();
NB: looking at the open source code, the bug seems to be in the RadioButtonGroup.addInstance() function:
mx_internal function addInstance(instance:RadioButton):void
should use Event.REMOVED_FROM_STAGE instead of Event.REMOVED.