//========================================================این کد ها به اکشن اسکریپت 3 هستند و باید تبدیل به اکشن اسکریپت 2 شوند
import farsi.FarsiStyle;
var FS:Farsistyle=new FarsiStyle();
var mainXML:XML=new XML();
var mURLLoader:URLLoader=new URLLoader();
mURLLoader.load(new URLRequest("MainXML.xml"));
mURLLoader.addEventListener(Event.COMPLETE,CompleteFunction);
function CompleteFunction(evt:Event):Void
{
mainXML=XML(evt.target.data);
var button_label:Array = new Array(mainXML.Farsi.Lables[0][email protected](),mainXML.Farsi.Lables[1][email protected](),mainXML.Farsi.Lables[2][email protected](),mainXML.Farsi.Lables[3][email protected](),mainXML.Farsi.Lables[4][email protected](),mainXML.Farsi.Lables[5][email protected]());
var total_page:Number = button_label.length;
//======================================================از اینجا به بعد کدها به زبان اکشن اسکریپت 2 هستند
flashmo_button._visible = false;
for( i = 0; i < total_page; i++ )
{
flashmo_button.duplicateMovieClip("flashmo_button" + i, i);
this["flashmo_button" + i]._x = flashmo_button._x + (flashmo_button._width+1) * i;
this["flashmo_button" + i]._y = flashmo_button._y;
//*******************************************************************************************************
this["flashmo_button" + i].label_txt =FS.convert(this["flashmo_button" + i].label_txt,button_label[i]);
//********************************************************************************************************
this["flashmo_button" + i].no = i;
}
function change_page(no)
{
for( i = 0; i < total_page; i++ )
{
this["flashmo_button" + i].button_mc._visible = true;
this["flashmo_button" + i].graphic_bg1._visible = true;
this["flashmo_button" + i].graphic_bg2._visible = false;
}
this["flashmo_button" + no].button_mc._visible = false;
this["flashmo_button" + no].graphic_bg1._visible = false;
this["flashmo_button" + no].graphic_bg2._visible = true;
_root.page = no + 1;
_root.play();
}
change_page(0);
var theMenu:ContextMenu = new ContextMenu();
theMenu.hideBuiltInItems(); _root.menu = theMenu;
var item:ContextMenuItem = new ContextMenuItem("Created by www.flashmo.com", flashmo);
theMenu.customItems[0] = item;
function flashmo() { getURL("http://www.flashmo.com"); }
}