Flex·ÖÒ³×é¼þ
ÓкÃÓõĶ«Î÷Ò»¶¨Òª¹²Ïí¡£
PaginationDataGrid.mxmlÎļþ·ÖÒ³×é¼þ
<?xml version="1.0" encoding="utf-8"?>
<mx:Canvas xmlns:mx="http://www.adobe.com/2006/mxml" width="400" height="300">
<mx:Script source="../../../common/utils/Common.as"/>
<mx:Script>
<!--[CDATA[
import mx.core.Application;
import mx.containers.Grid;
import mx.managers.PopUpManager;
import mx.events.CloseEvent;
import mx.containers.TitleWindow;
import mx.controls.listClasses.ListData;
import mx.events.DataGridEvent;
import mx.controls.dataGridClasses.DataGridColumn;
import mx.controls.CheckBox;
import mx.controls.Alert;
import common.controls.ItsmHttpService;
import mx.rpc.http.HTTPService;
import com.adobe.serialization.json.JSON;
import mx.rpc.events.ResultEvent;
import mx.collections.ArrayCollection;
/* ·ÖÒ³DataGrid
* ¼ÓÁËÒ»¸öpageSize,ÓÃÀ´¿ØÖÆÿҳÏÔʾµÄÐÐÊý£¬¿ÉÒÔÔÚµ÷ÓÃÕâ¸ö×é¼þµÄʱºòΪpageSizeÊôÐÔ¸³Öµ£¬
* ĬÈÏΪÿҳÏÔʾ10ÐÐÊý¾Ý,²»ÐèҪΪDataGridÖ¸¶¨¸ß¶È¡£
*/
[Bindable]
public var rowClick:Function;
[Bindable]
public var dataUrl:String; //»ñÈ¡Êý¾ÝµÄurlµØÖ·
[Bindable]
public var arrColumns:Array; //DataGridÁÐ,ÔÚµ÷ÓÃʱÐèҪΪÕâ¸öÊý×éÉèÖÃÊý¾Ý
[Bindable]
public var queryParams:Object={}; //²éѯÐèÒªµÄ²ÎÊý
[Bindable]
public var ifShowCheck:Boolean=true; //ÊÇ·ñÓÐcheck¿ò½øÐÐÑ¡Ôñ£¬Ä¬ÈÏÓÐ
[Bindable]
public var idProperty:String="id"; //Èç¹ûÐèÒªcheck½øÐÐÑ¡Ôñ£¬Ö¸¶¨Ö÷¼üÊôÐÔ¡£Ä¬ÈÏΪ“id”
[Bindable]
public var acPageData:ArrayCollection=new ArrayCollection(); //µ±Ç°Ò³Êý¾Ý
[Bindable]
private var pageSize:int=10; //ÿҳÏÔʾÐÐÊý
[Bindable]
private var totalPage:int=0; //×ÜÒ³Êý
[Bindable]
private var totalCount:int=0; //×ܼǼÊý
[Bindable]
private var currentPage:int=0; //µ±Ç°Ò³
//Ðü¸¡´°¿Ú¶ÔÏó
[Bindable]
public var inf
Ïà¹ØÎĵµ£º
»ùÔªÊý¾ÝÀàÐÍ°üÀ¨ Boolean¡¢int¡¢Null¡¢Number¡¢String¡¢uint ºÍ void¡£ActionScript ºËÐÄÀ໹¶¨ÒåÏÂÁи´ÔÓÊý¾ÝÀàÐÍ£º
Object¡¢ Array¡¢Date¡¢Error¡¢Function¡¢RegExp¡¢XML ºÍ XMLList¡£
Boolean Êý¾ÝÀàÐÍ
Boolean Êý¾ÝÀàÐÍ°üº¬Á½¸öÖµ£ºtrue ºÍ false¡£¶ÔÓÚ Boolean ÀàÐ͵ıäÁ¿£¬ÆäËüÈκÎÖµ¶¼ÊÇÎÞЧµÄ¡£Ò ......
ÑùÕÅͼ£º
ʹÓ÷½·¨£º
ÉèÖÃApplication±êÇ©µÄpreloaderΪ MyComponent.MyDownloadProgressBar
<mx:Application preloader="MyComponent.MyDownloadProgressBar" >
ÏÂÃæÊÇMyDownloadProgressBar.asµÄ´úÂ룺
package MyComponent
{
import flash.display.*;
import flash.events.*;
import flash.filte ......
ÔÚFlexÖÐ,µ±ÓжàÕŲ»¹æÔòµÄͼƬƴ´Õ(ÿÕÅСµÄ¶¼ÊÇpng¸ñʽ,ÓÃImage´æ·Å)ÔÚÒ»Æðʱ(²»ÖغÏ),ÔõÑùÅжÏÊó±êÂäÔÚÄÄÕÅͼƬÉÏ°¡? Èç¹ûÓÃÊó±ê×ø±êµãÀ´ÅжϵĻ°,¾Í±È½ÏµÄÂé·³ÁË,¿öÇÒÓÖÊDz»¹æÔòµÄͼƬÁË(ÏÂÃæÊÇÒ»¸öÁÐ×Ó,ÔõôÅжÏÂäÔÚÄÄÕžßÌåµÄÂÖÀªÍ¼ÉÏ°¡(±ÈÈç:³É¶¼)). лл! ......
///
Ç°ÃæµÄ¼¸ºõ¶¼ÊÇÔÚ³Ê飬ÊÇÒª¸ÄÒ»ÏÂÁË
Tips:
1¡¢Flex
BuilderÏîÄ¿»òActionScriptÏîÄ¿»á×÷Ϊһ¸öÈÝÆ÷£¬ÈÝÄÉËùÓÐ×ʲú¡£×ʲú¼´ÏîÄ¿ÔËÐÐËùÐèµÄ¸÷ÖÖ¸÷ÑùµÄÎļþ£¨MXML¡¢AS¡¢Í¼Æ¬ºÍXMLµÈ£©¡£Flex
Builder»áΪÎÒÃǸú×ÙÕâЩ²»Í¬µÄ×ʲú£¬¹ÊFlex
BuilderÒªÇóÎÒÃÇÖ»ÄÜÔÚÏîÄ¿ÄÚ´´½¨»òµ¼ÈëÕâЩ×ʲú¡£
2¡¢Í¨³£Ö»ÓÐÒ»¸öMXMLÎļþ ......
ÔÚ¹¹½¨¸»ÒòÌØÍøÓ¦ÓóÌÐòGUI·½ÃæÓÐÁ˺ܺô¦ÀíÄÜÁ¦ºó£¬ÏÖÔÚÎÒÃǰѽ¹µãתÏòÏòGUIÖзÅÈëÄÚÈÝ¡£Èç²»ÄÜ°ÑËüÃÇÓëÊý¾ÝÔ´ÁªÏµÆðÀ´£¬Ò»Çж¼ÎÞÒâÒå¡£
################
#
Êý¾ÝÔ´
################
¹ýÈ¥£¬Ò»°ã½«Êý¾Ý¿âÖ±½ÓÒýÓõ½¶¯Ì¬Ò³ÃæÄ£°å¡£ÏÖÔÚÇ÷ÊÆÊÇ·ÅÆú¹ýÈ¥×ö·¨£¬ÊµÏ ......