function Redimensionne() {
nRapportWHImage = imageCouranteMC._width/imageCouranteMC._height;
wMax = zoneAffichage_mc._width;
hMax = zoneAffichage_mc._height;
nRapportWHCadre = wMax/hMax;
if (nRapportWHImage>nRapportWHCadre) {
trace("paysage");
format = "paysage";
imageCouranteMC._width = wMax;
imageCouranteMC._height = wMax/nRapportWHImage;
imageCouranteMC._x = zoneAffichage_mc._x;
imageCouranteMC._y = (((hMax-imageCouranteMC._height)/2)+zoneAffichage_mc._y);
} else {
trace("portrait");
format = "portrait";
imageCouranteMC._height = hMax;
imageCouranteMC._width = hMax*nRapportWHImage;
imageCouranteMC._x = (((wMax-imageCouranteMC._width)/2)+zoneAffichage_mc._x);
imageCouranteMC._y = zoneAffichage_mc._y;
}
}
changeAlpha = function () {
changement = new Tween(imageChargementMC, "_alpha", Regular.easeOut, 0, 100, 1, true);
changement2 = new Tween(imageCouranteMC, "_alpha", Regular.easeOut, 100, 0, 1, true);
};
function moveBords() {
mask_mc;
Move1 = new Tween(bords_mc, "_height", Regular.easeOut, bords_mc._height, imageCouranteMC._height+10, 0.3, true);
Move2 = new Tween(bords_mc, "_width", Regular.easeOut, bords_mc._width, imageCouranteMC._width+10, 0.3, true);
Move3 = new Tween(mask_mc, "_height", Regular.easeOut, mask_mc._height, imageCouranteMC._height-10, 0.5, true);
Move4 = new Tween(mask_mc, "_width", Regular.easeOut, mask_mc._width, imageCouranteMC._width-10, 0.5, true);
}
Vous n’avez pas trouvé la réponse que vous recherchez ?
Posez votre question