Details
-
Bug
-
Status: Closed
-
Minor
-
Resolution: Later
-
Adobe Flex SDK Previous
-
None
-
None
-
Affected OS(s): Windows
Affected OS(s):
Browser: Internet Explorer 7.x
Language Found: English
Description
Steps to reproduce:
I dont know if this is expected behaviour or not.
1.
the following code
in my model i have an instantiated class 'assets' and embed 2 images
[Embed(source="red.png")]
public var Red:Class;
[Embed(source="red.png")]
public var Red:Class;
in a view I have an <mx:image with it's source set to one of the embedded assets
<mx:Image id="anIcon" source="
{asset.Red}" />
Then create a Timer, say every 10 seconds.
In that timer toggle the .source property of the mx:image 'anIcon'
[Timer, toggles image source]
{
anIcon.source = asset.Red;
then, on next pass
anIcon.source = asset.Black;
then on next pass back to first
}
- I only expect to see 1 instance of each the of asset.Red & asset.Black in profiler
Actual Results:
When looking at the instances with profiler:
on each pass of the Timer a new instance of either 'asset.Red' or 'asset.Black' is created
after a few minutes there are lots of instances of each asset
Expected Results:
only a single instance of 'asset.Red' and 'asset.Black'
with the mx:image .source having it's reference changed.
Workaround (if any):