This content has been marked as final. Show 10 replies
the child hasn't be scaled so checking its width should return its original width. this is consistant and expected behavior because the child's _width hasn't changed: the coordinate space in which the child is located has been scaled.
if you want to check the results of all manipulations affecting a child (or even more deeply nested) movieclip (ie, those applied to the movieclip or its ancestors), use the concatenatedMatrix property of the descendant movieclip's transform property.
the child hasnt been scaled???
i see on the stage that it is scaled!
when i change the width of the parent the child grows also
and when i check its width property i get the original width.
in order to get the actual width of the child i have to check the xscale property of the parent
again, the child isn't scaled (despite the fact that it will appear to change shape). the space it's in is scaled. that may be a subtle point but until you grasp it, you may have difficulty understanding this aspect of flash.
it might be easier to add a rectangle to your stage and rotate the stage. the rectangle appears to be rotated, but it's not.
read the 2nd paragraph of my above message to see how do deal with this should you be interested in all transformations affecting a descendant movieclip.
do you think that concatenatedMatrix will help me.
i have a mc that inclueds a picture frame and a few other mcs and also an emty mc that will contain a picture that i load using a movieClipLoader
the mcFrame pops up (i use a transition tween)
and when the picture is totaly loaded i want to resize it to fit into the frame.
the problem is that when the picture gets the new size the mcFrame transition is finished because the picture is a child of the mcFrame.
how can i work it out.
is mcPicView the frame and why are you changing mcPicView's _width and _height?
if i write
target_mc._width = int(picViewW*95/100)*100/mcPicView._xscale;
it is working but only if the transition was finished before the onLoadInit
if not, the transition finishes when the picture gets the new width (because it is a chiled)
the mcPicView is the parent mc that contain a picture frame and some other objects (like a dynamic textbox) and it contains also an empty mc
the mcPicView has to pop up from the point i press the mouse and it start from a size of zero towards its full size
delay execution of your onLoadInit() statements until your tweens complete.
is it possible??
i tried to use:
var myTween=new Tween(.......
here i put the onLoadInit
its not working.
it seems that the onLoadInit can not be delayed
onLoadInit can't be delayed. but you don't need to add that code to onLoadInit(). you could just use a timer to delay execution for 1 second or call a function with a tween_complete event and with your onLoadInit() and the 2nd time its called execute that code.