Details
-
Bug
-
Status: Closed
-
Critical
-
Resolution: Fixed
-
Adobe Flex SDK Previous
-
None
-
Affected OS(s): All OS Platforms
Affected OS(s): All OS Platforms
Browser: Internet Explorer 8.x
Language Found: English
Description
The following problem comes from AnimateTransformInstance.updateTransformCenter(). The method assumes that target will be a subclass of UIComponent (which is totally fair). However, in this example, the target is an imported FXG asset. Turns out those get imported as SpriteVisualElement. Since the SpriteVisualElement doesn't have accessors for transformX,Y,Z... it throws the RTE.
To fix, we need to either add accessors .transformX,Y,Z to SpriteVisualElement, or we need to assure target is typeof(UIComponent) in updateTransformCenter(). I believe the former idea is the most performant.
Steps to reproduce:
1. Extract, compile, and run the "Grow.fxp" located in bug 23240.
2. Mouse over the rectangle... boom.
Actual Results:
ReferenceError: Error #1069: Property transformX not found on assets.graphics.Graphic1 and there is no default value.
at spark.effects.supportClasses::AnimateTransformInstance/updateTransformCenter()[E:\dev\trunk\frameworks\projects\spark\src\spark\effects\supportClasses\AnimateTransformInstance.as:564]
at spark.effects.supportClasses::AnimateTransformInstance/play()[E:\dev\trunk\frameworks\projects\spark\src\spark\effects\supportClasses\AnimateTransformInstance.as:484]
at spark.effects.supportClasses::AnimateInstance/startEffect()[E:\dev\trunk\frameworks\projects\spark\src\spark\effects\supportClasses\AnimateInstance.as:411]
at spark.effects.supportClasses::AnimateTransformInstance/startEffect()[E:\dev\trunk\frameworks\projects\spark\src\spark\effects\supportClasses\AnimateTransformInstance.as:242]
at mx.effects.effectClasses::ParallelInstance/play()[E:\dev\trunk\frameworks\projects\framework\src\mx\effects\effectClasses\ParallelInstance.as:274]
at mx.effects::EffectInstance/startEffect()[E:\dev\trunk\frameworks\projects\framework\src\mx\effects\EffectInstance.as:680]
at mx.effects.effectClasses::ParallelInstance/play()[E:\dev\trunk\frameworks\projects\framework\src\mx\effects\effectClasses\ParallelInstance.as:274]
at mx.effects::EffectInstance/startEffect()[E:\dev\trunk\frameworks\projects\framework\src\mx\effects\EffectInstance.as:680]
at mx.effects::Effect/play()[E:\dev\trunk\frameworks\projects\framework\src\mx\effects\Effect.as:1216]
at mx.core::UIComponent/commitCurrentState()[E:\dev\trunk\frameworks\projects\framework\src\mx\core\UIComponent.as:9344]
at mx.core::UIComponent/setCurrentState()[E:\dev\trunk\frameworks\projects\framework\src\mx\core\UIComponent.as:9220]
at mx.core::UIComponent/set currentState()[E:\dev\trunk\frameworks\projects\framework\src\mx\core\UIComponent.as:5740]
at Main/customComponent1_rollOverHandler()[C:\Documents and Settings\mfinitz\My Documents\Flex Builder 3\Untitled_1\src\Main.mxml:10]
at Main/__customcomponent11_rollOver()[C:\Documents and Settings\mfinitz\My Documents\Flex Builder 3\Untitled_1\src\Main.mxml:22]
Expected Results:
The animation should play.
Workaround (if any):
Don't animate targets of type SpriteVisualElement