Hola.
Este es el código que deseo pasa a AS2:
Cita: import com.yofla.flashzoomer.FlashZoomerApp;
// JavaScript API
try{
ExternalInterface.addCallback("newImage", setNewImage);
}
catch (e:*){
// dont trigger error if not runnig the swf in a webpage
}
// Initialize the flashZoomerApp
// Usage: FlashZoomer(theme)
// theme - required - the themimg movie
var flashZoomer: FlashZoomerApp = new FlashZoomerApp(flashZoomerTheme);
// get imagePath or use default
var myImageSrc : String = root.loaderInfo.parameters.imgSrc;
if(!myImageSrc) myImageSrc = "sample.jpg";
// get zoomSteps or use default
var myZoomSteps : uint = root.loaderInfo.parameters.zoomSteps;
if(!myZoomSteps) myZoomSteps = 5;
// get start state
var startState : String = root.loaderInfo.parameters.startState;
if(!startState) startState = "select";
// get start state
var maxZoom : uint = root.loaderInfo.parameters.maxZoom;
if(!maxZoom) maxZoom = 100;
// get start zoom
var startZoom : uint = root.loaderInfo.parameters.startZoom;
// set image path
flashZoomer.imgSrc = myImageSrc;
// set zoom steps
flashZoomer.zoomSteps = myZoomSteps;
// set start state
flashZoomer.startState = startState;
// set max zoom
flashZoomer.maxZoom = maxZoom;
// set start zoom
flashZoomer.startZoom = startZoom;
// separate domains on which is the tool by semicolon, empty string to disable security feature
//flashZoomer.domains = "www.yofla.com;localhost";
flashZoomer.domains = "";
// start the FlashZoomerApp
flashZoomer.start();
// function for JavaScritp API
function setNewImage( s : String): void{
flashZoomer.setNewImage(s);
}