随笔分类 -  ActionScript 3.0

上一页 1 ··· 6 7 8 9 10
(Flash AIR Flex)
[Flex] 组件Tree系列 —— 支持CheckBox组件
摘要:主程序mxml: 1 2 3 4 5 8 9 10 11 12 13 @namespace s "library://ns.adobe.com/flex/spark"; 14 @... 阅读全文
posted @ 2015-03-02 15:00 晏过留痕 阅读(388) 评论(0) 推荐(0) 编辑
[Flex] 组件Tree系列 —— 实现右键拓展功能
摘要:主程序mxml: 1 2 3 4 5 9 10 28 29 30 31 ... 阅读全文
posted @ 2015-03-02 14:47 晏过留痕 阅读(521) 评论(0) 推荐(0) 编辑
[Flex] 组件Tree系列 —— 作为PopUpButton的弹出菜单
摘要:mxml: 1 2 3 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 ... 阅读全文
posted @ 2015-03-02 14:33 晏过留痕 阅读(419) 评论(0) 推荐(0) 编辑
[ActionScript3.0] 使用FileReferenceList处理多个文件上载
摘要:1 package 2 { 3 import flash.display.Sprite; 4 import flash.events.DataEvent; 5 import flash.events.Event; 6 import flash.event... 阅读全文
posted @ 2015-02-15 10:43 晏过留痕 阅读(256) 评论(0) 推荐(0) 编辑
[ActionScript3.0] 使用FileReference处理单个文件的上载
摘要:1 package 2 { 3 import flash.display.SimpleButton; 4 import flash.display.Sprite; 5 import flash.errors.IllegalOperationError; 6 ... 阅读全文
posted @ 2015-02-15 10:31 晏过留痕 阅读(583) 评论(0) 推荐(0) 编辑
[ActionScript3.0] AS3利用ExternalInterface与js通信
摘要:AS3代码,可做文档类; 1 package { 2 import flash.display.Sprite; 3 import flash.events.*; 4 import flash.external.ExternalInterface; 5 import f... 阅读全文
posted @ 2015-02-15 10:15 晏过留痕 阅读(350) 评论(0) 推荐(0) 编辑
[ActionScript3.0] 逻辑或"||=" ,等于"=="和全等于"==="
摘要:function a(o:Object):void { o||=new Object(); trace(o);}//此上下两个方法作用是一样的function b(o:Object):void { if(o === null){ o = new Object(); } trace... 阅读全文
posted @ 2015-02-14 17:04 晏过留痕 阅读(285) 评论(0) 推荐(0) 编辑
[ActionScript3.0] 传递任意数量的参数
摘要:function setAgument(a:int,...rest):void{ for(var i:int=0;i<rest.length;i++){ trace(rest[i]); }}setAgument(5,"1","fs",3,4);//1 fs 3 4 阅读全文
posted @ 2015-02-14 17:02 晏过留痕 阅读(159) 评论(0) 推荐(0) 编辑
[ActionScript3.0] 深表复制
摘要:function clone(obj:Object):Object{ var byteArray:ByteArray = new ByteArray(); byteArray.writeObject(obj); byteArray.position = 0; return byteArray... 阅读全文
posted @ 2015-02-14 17:00 晏过留痕 阅读(235) 评论(0) 推荐(0) 编辑
[ActionScript3.0] 为内建类添加方法
摘要:通过使用prototype在继承内建类特性的同时加入新方法Array.prototype.removeElement = function (item:*):void { var index:int = this.indexOf(item); if(index>-1){ this.sp... 阅读全文
posted @ 2015-02-14 16:58 晏过留痕 阅读(503) 评论(0) 推荐(0) 编辑

上一页 1 ··· 6 7 8 9 10