ActionScript functions in the flash player 7

I need this ActionScript functions in the flash player 7, but, only function in the 6, I am trying to arrange to function in the 7, but all my attempts had given wrong, if somebody will be able to help.

// Action script…
// [Action in Frame 1]
function ExtDef(s) {
var _l1 = s;
_l1.indexOf(“.”) != -1 ? (_l1) : (_l1+“.jpg”);
return (_l1.indexOf(“.”) != -1 ? (_l1) : (_l1+“.jpg”));
}
// End of the function
imagem = new Array(_root.i1, _root.i2, _root.i3, _root.i4, _root.i5, _root.i6, _root.i7, _root.i8, _root.i9, _root.i10);
var QtdImagens = 0;
while (QtdImagens<10 && imagem[QtdImagens] != null) {
QtdImagens++;
}
// end while
var pic_arr = [ExtDef(_root.i1), ExtDef(_root.i2), ExtDef(_root.i3), ExtDef(_root.i4), ExtDef(_root.i5), ExtDef(_root.i6), ExtDef(_root.i7), ExtDef(_root.i8), ExtDef(_root.i9), ExtDef(_root.i10)];
pic_arr.length = QtdImagens;
var currentSlide = 0;
this.attachMovie(“slideshow”, “show”, 1, {_x:0, _y:0, _visible:false, fps:15, nFrames:5, alphaIncr:6, slides_arr:pic_arr, slideDepth:1, repeat:true, slideTracker:“currentSlide”});
show.addListener(this);
this.onAllSlidesLoaded = function() {
show._visible = true;
show.beginTransitions();
};
this.onShowOver = function() {
};
pausa_mc.onRelease = function() {
// if playing
if (this._currentframe == 1) {
this.gotoAndStop(“stopped”);
// para a imagem no slide atual
show.stopTransitions();
// certifique-se que a imagem atual está indicando alpha 100
for (var t = 0; t<pic_arr.length; t++) {
if (t == currentSlide) {
show[“slide”+t]._alpha = 100;
} else {
show[“slide”+t]._alpha = 0;
}
}
// if parado
} else {
// começa acima transições do slide atual
this.gotoAndStop(“playing”);
show.activateInSeq(currentSlide);
}
};