To fazendo um site onde o conteúdo das seções ficam dentro de um movieClip q é duplicado por AS.
No preview do Flash aparece tudo certinho mas qdo abro pelo Flash Player o fundo (branco) some a fonte passa de estilo estático pra dinâmico (sem alias).
Será que é pq.. hehe.. não posso falar, ceis sabem!
Bom.. aí vai o c0de
gumidek = 5;
next_photo = true;
function showPhoto(num, dir) {
if (next_photo) {
old_ph = eval("photo_"+old_num);
if (num != old_num) {
next_photo = false;
ph = eval("photo_"+num);
if (dir == "h") {
phW = 575;
phH = 385;
phY = 215;
} else {
phH = 575;
phW = 385;
phY = 25;
}
moveAll = setInterval(function () {
spA1 = ph.maska._width;
difA1 = phW-spA1;
AStp1 = difA1/gumidek;
spA2 = ph.maska._height;
difA2 = phH-spA2;
AStp2 = difA2/gumidek;
spA3 = ph._y;
difA3 = phY-spA3;
AStp3 = difA3/gumidek;
_root.ph.maska._width = spA1+AStp1;
_root.ph.maska._height = spA2+AStp2;
_root.ph._y = spA3+AStp3;
_root.ph.btt._width = _root.ph.maska._width;
_root.ph.btt._height = _root.ph.maska._height;
_root.ph.title._x = ph.maska._width-ph.title._width;
if (ph.maska._width+5>=phW) {
finish = true;
_root.ph.maska._width = phW;
_root.ph.maska._height = phH;
_root.ph._y = phY;
_root.ph.btt._width = _root.ph.maska._width;
_root.ph.btt._height = _root.ph.maska._height;
_root.ph.title._x = ph.maska._width-ph.title._width;
}
for (i=1; i<album.length+1; i++) {
move_ph = eval("photo_"+i);
if (i == old_num) {
if (!finish) {
spA1x = move_ph.btt._width;
difA1x = 14-spA1x;
AStp1x = difA1x/gumidek;
spA2x = move_ph.btt._height;
difA2x = 385-spA2x;
AStp2x = difA2x/gumidek;
spA3x = move_ph._y;
difA3x = 215-spA3x;
AStp3x = difA3x/gumidek;
_root.move_ph.btt._width = spA1x+AStp1x;
_root.move_ph.btt._height = spA2x+AStp2x;
move_ph.maska._width = _root.move_ph.btt._width;
move_ph.maska._height = _root.move_ph.btt._height;
_root.move_ph._y = spA3x+AStp3x;
move_ph.title._x = move_ph.maska._width-move_ph.title._width;
move_ph.title._visible = false;
} else {
_root.move_ph.btt._width = 14;
_root.move_ph.btt._height = 385;
move_ph.maska._width = 14;
move_ph.maska._height = 385;
_root.move_ph._y = 215;
move_ph.title._x = 0;
move_ph.title._visible = false;
}
}
if (i>1) {
move_ph._x = eval("photo_"+(i-1))._x+eval("photo_"+(i-1)).maska._width+3;
}
if (i != num) {
move_ph._alpha = 50;
} else {
move_ph._alpha = 100;
}
}
if (ph.maska._width == phW) {
finish = false;
old_num = num;
old_dir = dir;
next_photo = true;
clearInterval(moveAll);
}
updateAfterEvent;
}, 20);
} else {
next_photo = false;
moveAll = setInterval(function () {
spA1x = old_ph.btt._width;
difA1x = 14-spA1x;
AStp1x = difA1x/gumidek;
spA2x = old_ph.btt._height;
difA2x = 385-spA2x;
AStp2x = difA2x/gumidek;
spA3x = old_ph._y;
difA3x = 215-spA3x;
AStp3x = difA3x/gumidek;
_root.old_ph.btt._width = spA1x+AStp1x;
_root.old_ph.btt._height = spA2x+AStp2x;
old_ph.maska._width = _root.old_ph.btt._width;
old_ph.maska._height = _root.old_ph.btt._height;
_root.old_ph._y = spA3x+AStp3x;
old_ph.title._x = 0;
old_ph.title._visible = false;
if (old_ph.btt._width-2<=14) {
old_num = 0;
old_dir = "";
clearInterval(moveAll);
next_photo = true;
}
for (i=1; i<album.length+1; i++) {
move_ph = eval("photo_"+i);
if (i>1) {
move_ph._x = eval("photo_"+(i-1))._x+eval("photo_"+(i-1)).maska._width+3;
}
}
if (old_ph.btt._width-2<=14) {
for (i=1; i<album.length+1; i++) {
move_ph = eval("photo_"+i);
move_ph._alpha = 100;
move_ph.btt._width = 14;
move_ph.btt._height = 385;
}
_root.old_ph.btt._width = 14;
_root.old_ph.btt._height = 385;
old_ph.maska._width = 14;
old_ph.maska._height = 385;
_root.old_ph._y = 215;
old_ph.title._x = 0;
old_ph.title._visible = false;
for (i=1; i<album.length+1; i++) {
move_ph = eval("photo_"+i);
if (i>1) {
move_ph._x = eval("photo_"+(i-1))._x+eval("photo_"+(i-1)).maska._width+3;
}
}
}
updateAfterEvent;
}, 20);
}
}
}
function createAlbum(albumName) {
album = eval(albumName);
for (i=1; i<eval(albumName).length+1; i++) {
if (i>1) {
photo_1.duplicateMovieClip("photo_"+i, eval(albumName).length-i);
eval("photo_"+i)._x = 17*(i-1);
} else {
photo_1._x = 0;
}
ph = eval("photo_"+i);
ph._y = 215;
ph.title.title = eval(albumName)[i-1][0];
ph.title.tit.autoSize = "left";
ph.title.bg._width = ph.title.tit._width-2;
ph.title._visible = false;
ph.load_photo.setMask(ph.maska);
ph.maska._x = 0;
ph.maska._y = 0;
ph.maska._width = 14;
ph.maska._height = 385;
ph.load_photo.l_photo.loadMovie(albumName+"/"+eval(albumName)[i-1][0].substring(0, 2)+".swf", 0);
ph.ph_num = Number(eval(albumName)[i-1][0].substring(0, 2));
ph.typ = eval(albumName)[i-1][1];
}
}
function showPopis(ph_number) {
if (ph_number != 0) {
eval("photo_"+ph_number).title._visible = true;
old_number = ph_number;
} else {
if (old_num != old_number) {
eval("photo_"+old_number).title._visible = false;
}
}
}
Não sei qtas vezes vou postar esse código aqui... aiai.. :/










