1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39
|
<?xml version="1.0" encoding="utf-8"?>
<mx:ViewStack xmlns:mx="http://www.adobe.com/2006/mxml" xmlns:composant="composant.*" xmlns:local="*" selectedIndex="1"
width="146" height="128">
<mx:Metadata>
[Event(name="templateSelectionne", type="flash.events.Event")]
</mx:Metadata>
<mx:Script>
private function creationComplete():void {
//Alert.show("creationComplete");
var im:ImageEvolue = new ImageEvolue();
//on choisit quelle image on attribue
im.source = "icons/logo.png";
im.width = 10;
im.height = 12;
im.toolTip = "test tooltip";
im.nouvelElement = true;
im.x = 10;
im.y = 20;
p.addChild(im);
snapUI.source = new Bitmap(ImageSnapshot.captureBitmapData(p,null,null,null,null,true));
}
</mx:Script>
<local:Page id="p"/>
<mx:VBox width="146" alpha="1" height="128" backgroundColor="#FFFFFF" rollOver="onRollOver()"
rollOut="onRollOut()" horizontalAlign="center" creationPolicy="all"
creationComplete="initApercuCentral()/**Alert.show('creation complete')*/"
toolTip="Auteur : {_auteur}, text : {nomTemplate}" backgroundAlpha="0"
horizontalScrollPolicy="off" verticalScrollPolicy="off">
<mx:Image creationComplete="creationComplete()" id="snapUI" width="126" height="95"/>
<mx:Label text="valeur de {_auteur}" id="label2"/>
</mx:VBox>
</mx:ViewStack> |
Partager