flex AdvancedDataGrid问题
在AdvancedDataGrid控件中,使用itemRenderer在一列中加入linkbutton等控件,但是又一个问题,就是在AdvancedDataGrid第一列(树形)分组的行上也会有linkbutton,如何能让分组那行没有linkbutton呢
<mx:AdvancedDataGrid id="myVM" width="100%" height="100%" textAlign="center" defaultLeafIcon="{null}" folderOpenIcon="{null}" folderClosedIcon="{null}" displayItemsExpanded="true" doubleClickEnabled="true" itemDoubleClick="myVM_itemDoubleClickHandler(event)"> <mx:dataProvider> <mx:GroupingCollection id="vm" source="{arraylist}"> <mx:Grouping> <mx:GroupingField name="room_name"/> <mx:GroupingField name="team_name"/> </mx:Grouping> </mx:GroupingCollection> </mx:dataProvider> <mx:columns> <mx:AdvancedDataGridColumn headerText="虚拟机主机名" textAlign="left" dataField="vm_name"/> <mx:AdvancedDataGridColumn headerText="虚拟机IP地址" dataField="vm_ip" width="100"/> <mx:AdvancedDataGridColumn headerText="虚拟机域账号" textAlign="left" dataField="domain_account" width="100"/> <mx:AdvancedDataGridColumn headerText="虚拟机CPU数" dataField="vm_cpu_num" width="80"/> <mx:AdvancedDataGridColumn headerText="虚拟机内存" dataField="vm_mem" width="100"/> <mx:AdvancedDataGridColumn headerText="虚拟机主频" dataField="vm_hz" width="80"/> <mx:AdvancedDataGridColumn headerText="虚拟机硬盘数" dataField="vm_disk_num" width="80"/> <mx:AdvancedDataGridColumn textAlign="center" headerText="修改" width="80"> <mx:itemRenderer> <mx:Component> <mx:LinkButton useHandCursor="true" buttonMode="true" click="outerDocument.upp_vm_list_clickHandler(this)" icon="@Embed(source='assets/styles/default/images/icons/application_form_edit.png')"/> </mx:Component> </mx:itemRenderer> </mx:AdvancedDataGridColumn> <mx:AdvancedDataGridColumn textAlign="center" headerText="删除" width="80"> <mx:itemRenderer> <mx:Component> <mx:LinkButton useHandCursor="true" buttonMode="true" click="outerDocument.del_vm_list_clickHandler(this)" icon="@Embed(source='assets/styles/default/images/icons/cancel.png')"/> </mx:Component> </mx:itemRenderer> </mx:AdvancedDataGridColumn> </mx:columns> </mx:AdvancedDataGrid>