`
兩ting
  • 浏览: 75817 次
  • 性别: Icon_minigender_2
  • 来自: 成都
社区版块
存档分类
最新评论

flex中弹出确认对话框

    博客分类:
  • flex
阅读更多
Xml代码 复制代码 收藏代码
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" backgroundColor="black" layout="horizontal">
  3. <mx:Script>
  4. <![CDATA[
  5. import mx.events.CloseEvent;
  6. import mx.controls.Alert;
  7. public function deleteConfirm():void{
  8. Alert.yesLabel = 'yes';
  9. Alert.noLabel = 'no';
  10. Alert.cancelLabel = 'cancel';
  11. Alert.show('确认要删除吗','info',1|2|8,this,back);
  12. }
  13. public function back(event:CloseEvent):void{
  14. if(event.detail==Alert.YES){
  15. Alert.show('削除しました');
  16. }
  17. }
  18. ]]>
  19. </mx:Script>
  20. <mx:Button label="削除" click="deleteConfirm()"/>
  21. </mx:Application>
<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" backgroundColor="black" layout="horizontal">
	<mx:Script>
		<![CDATA[
			import mx.events.CloseEvent;
			import mx.controls.Alert;
			public function deleteConfirm():void{
				Alert.yesLabel = 'yes';
				Alert.noLabel = 'no';
				Alert.cancelLabel = 'cancel';
				Alert.show('确认要删除吗','info',1|2|8,this,back);	
			}
			public function back(event:CloseEvent):void{
				if(event.detail==Alert.YES){
					Alert.show('削除しました');
				}
			}
		]]>
	</mx:Script>
	<mx:Button label="削除" click="deleteConfirm()"/>
</mx:Application>
分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics