This content has been marked as final. Show 7 replies
are you using a true button or a movieclip button?
a true button.
actually, that doesn't matter if all you want to do is position your jpg. if you want to center it, then you'll needs its _width and _height properties and those are not available to flash until downloading is complete. and in that situation i'd need to know you were using a true button.
thx.. I see.
Well, actually, this solution could work but then, i have to add the location code for all the scripts (for all photos...) and that's a lot.
In my case i would prefer not to move the _mc and for a few photos (the vertical ones actually) add something to tune its placing. Until now, I proceeded this way: I have a fixed position of the _mc in Flash and the jpg is placed at the top-left corner of the _mc.
Only for those few smaller or vertical jpg, i'd like to change the placing... A kind of center jpg function...
Do u see what I mean...?
centered with respect to the stage or something else?
no, center within the mc. In other words, i'd like to keep the mc static (so I don't have to script its position each time i call it) and be able to (only wehen needed then) center (or else) the loaded jpg within the clip. Since it happens for a few picts only, it saves me a lot of scripting.
Am i more clear? Thx for your attention.
if you're loading into bo_mc, you can't control where your loading image is going to be positioned inside bo_mc: the top left of your loading image will be placed at the center of bo_mc and there's no way to change that.
and your container movieclip (bo_mc) may, and probably should, be an empty movieclip with 0 width and 0 height. so, centering within bo_mc, in that situation, makes no sense.
and the only way to control the position of your loaded image is to control the position of bo_mc or one if its ancestors.
so, you're more clear but you can't do what you're thinking. you can't keep the mc (bo_mc) static and center the loaded jpg.
you can load into bo_mc and then position bo_mc so it's centered with respect to the stage or any other movieclip on-stage. that way your image will be centered.