[Bindable]
[Embed(source="../WebContent/images/SCport_con.png")]
public var scport_icon_con:Class;
[Bindable]
[Embed(source="../WebContent/images/SCport.png")]
public var scport_icon:Class;
private var port:PortDTO;
private var portZ:PortDTO;
public var imgA:Image;
public var imgZ:Image;
public function inti():void{
port=new PortDTO();
port.port_name="端口A";
port.port_row="01";
port.port_column="01";
port.port_id="0101";
portZ=new PortDTO();
portZ.port_name="端口Z";
portZ.port_row="02";
portZ.port_column="02";
portZ.port_id="0202";
imgA=new Image();
imgA.source=scport_icon;
imgA.data=port;
imgZ=new Image();
imgZ.source=scport_icon;
imgZ.data=portZ;
}
//获取图片对象
[Bindable]
public var imageAC:Array=new Array[imgA,imgZ];
这样写可以吗?