1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
| var myloader:Loader = new Loader();
btn1_btn.addEventListener(MouseEvent.CLICK,image1) ;
function image1(event:MouseEvent):void {
var request:URLRequest = new URLRequest("IMA_modeles.jpg");
myloader.load(request);
addChild(myloader);
myloader.x=36;
myloader.y=115;
}
btn2_btn.addEventListener(MouseEvent.CLICK, image2);
function image2(event:MouseEvent):void {
var request:URLRequest = new URLRequest("IMA_confiance.jpg");
myloader.load(request);
addChild(myloader);
myloader.x=36;
myloader.y=115;
} |
Partager