• 首页
  • 动态
  • 案例
  • 引擎社区
  • API
  • 文档
  • 示例
  • 引擎下载

大约有 1,305 项符合查询结果, 库内数据总量为 31,722 项。 (搜索耗时: 0.0082 秒)

1041. 点击list的时候触发的e.target永远是被点击的item? [ 50%]

...0;i<10;i++) { arr.push({my_clip:i}); } my_list.array=arr; my_list.renderHandler=new Handler(this,onRender); } private function onRender(cell:Box,index:int):void { // TODO Auto Generated method stub var cell:Box=my_list.getCell(index) as Box; var my_btn:Button=cell.getChildByName("my_btn") as Butt...

来源: Laya_社区 发布时间: 20161030

1042. laya.ui.List [ 50%]

...如果父节点手动设置为false,则不会更改)。 Sprite  mouseHandler : Handler单元格鼠标事件处理器(默认返回参数e:Event,index:int)。List mouseThrough : Boolean = false 鼠标事件与此对象的碰撞检测是否可穿透。碰撞检测发生在鼠标事件的捕获...

来源: Laya2.0_api 发布时间: 20190513

1043. Laya.loader.load(xx) 当地址""的时候,会报错。 [ 50%]

...,会报错。 laya 引擎是2.5的      Laya.loader.load(cg_url,Laya.Handler.create(this,()=>{             let tur:Laya.Texture = Laya.loader.getRes(cg_url);             if(tur)img_cg.graphics.drawImage(tur)         }),null,Laya.Loader.IMAGE);    这段...

来源: Laya_社区 发布时间: 20201130

1044. CheckBox属性详解(TypeScript-IDE篇(TS)-IDE组件属性详解) [ 50%]

...执行onLoaded回调方法 Laya.loader.load([this.skin1,this.skin2],Laya.Handler.create(this,this.onLoaded)); } private onLoaded():void{ //创建一个CheckBox实例cb1 var cb1:Laya.CheckBox = new Laya.CheckBox(this.skin1); //添加到舞台上显示 Laya.stage.addChild(cb1); //设置checkbox的坐...

来源: Laya2.0_文档 发布时间: 20210715

1045. Panel初始化BUG [ 50%]

...看 onEnable(): void { Laya.loader.load("comp/image.png", Laya.Handler.create(this, this.onResReady)); } private onResReady() { let panel = new Laya.Panel(); Laya.stage.addChild(panel); panel.graphics.drawRect(0, 0, 300, 300, "#ffcccc"); panel.width = 300; panel.height = 300; pan...

来源: Laya_社区 发布时间: 20211108

1046. LayaAir引擎工具会员专属功能介绍(TypeScript-简介篇(TS)-LayaAir引擎简介) [ 49%]

...文件Image.json Laya.loader.load([{url: "res/Image.json", type: "plf"}], Handler.create(this, function():void { //在回调里,正常使用原来的图集 Laya.loader.load("res/atlas/comp.atlas", Handler.create(this, function():void { var img:Texture = Laya.loader.getRes("comp/comp.png"); var sp:...

来源: Laya2.0_文档 发布时间: 20210714

1047. 2D性能优化 · LayaAir3.4 · 引擎文档 · LAYABOX [ 49%]

...var sp=new Laya.Sprite(); sp.loadImage("res/apes/monkey2.png",0,0,0,0,Laya.Handler.create(this,function() { console.log(sp.width,sp.height); })); Laya.stage.addChild(sp); loadImage在加载完成的回调函数触发之后才可以正确获取宽高。 直接调用size设置: Laya.loader.load("res...

来源: Laya3.0_文档 发布时间: 20251010

1048. iframe页面嵌套下失焦(焦点在父窗口被聚焦),playMusic背景音乐播放无声音 [ 49%]

...音 public static function playSound(url:String, loops:int = 1, complete:Handler = null, soundClass:Class = null, startTime:Number = 0):SoundChannel { if ((!_isActive && loops != 0) || !url) return null; if (_muted) return null; _recoverWebAudio(); url = URL.formatURL(url); if (url == _tMusi...

来源: Laya_社区 发布时间: 20190115

1049. laya.ui.DialogManager [ 49%]

...s的normal模式。建议优先使用cacheAs代替。 Sprite  closeEffectHandler : Handler全局默认弹出对话框效果,可以设置一个效果代替默认的弹出效果,如果不想有任何效果,可以赋值为nullDialogManager customRenderEnable : Boolean[write-only] 设置是否...

来源: laya_api 发布时间: 20170929

1050. 小游戏子域程序加载到图集后,取图集内资源报错。 [ 49%]

...ivate function beginLoad():void { Laya.loader.load("res/images/rank.json", Handler.create(this, onLoaded)); } private function onLoaded():void { trace("加载成功"); var c:Image = new Image("rank/country.png"); Laya.stage.addChild(c); }  以上是子域项目中加载图集和取资源的代码...

来源: Laya_社区 发布时间: 20180830