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

大约有 236 项符合查询结果, 库内数据总量为 30,723 项。 (搜索耗时: 0.0038 秒)

11. 关于js继承类class的参数问题 [ 93%]

关于js继承类class的参数问题 Laya.class(LoginView, "LoginView", LoginUI) ; // 设置继承关系. 括号里第一个参数是一个方法,第三个是要继承的对象,第二个参数字符串是什么意思啊。 自己写了一个继承,Laya.class(LayaIndex,"LayaIndex",indexUI);...

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

12. 对话框点击空白处无法关闭 [ 91%]

... testUI=(function(_super){ function testUI(){ testUI.__super.call(this); } CLASS$(testUI,'ui.testUI',_super); var __proto__=testUI.prototype; __proto__.createChildren=function(){ laya.ui.Component.prototype.createChildren.call(this); this.createView(testUI.uiView); } testUI.uiView={"type":"Dialog","...

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

13. 请问UI之间的场景切换要怎么写 [ 90%]

...s.btn_wxsign.on(Laya.Event.CLICK,this,this.onWxSign); this.reset(); } Laya.class(sg_sign,"sg_sign",_super); var _proto = sg_sign.prototype; _proto.reset = function(){ Laya.SoundManager.playMusic('res/sound/sign_bgm.mp3',0); } _proto.onWxSign = function(e){ onWxSign1(); } return sg_sign; })(ui.sg_sig...

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

14. 升级引擎到1.7.19.1beta List报错问题 [ 89%]

...博 QZONE 微信 Calvin 赞同来自: 可以证实的,有如下场景: class PageList extends laya.ui.List {        constructor()      {           super();       }        protected initialize():void        {              super.initialize();              this...

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

15. js继承模式 [ 89%]

js继承模式     new function() { var className = 'BackGround'; window[className] = (function() { Laya.class(Class, className, Laya.Sprite); function Class() { Class.super(this); // this定义.. this.init(); } Class.prototype.init = function() { console.log(this); }; return Class; })(); } var _...

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

16. 续飞机大战 [ 89%]

...s.addChild(this.bg2); //创建一个帧循环,更新容器位置 }; Laya.class(BackGround,"BackGround",_super); return BackGround; }(Laya.Sprite));注意: 1、如果_super是传参过来的,直接写_super.call(this)即可,如果不是直接写BackGround.__super(this)即可,两种写法(...

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

17. 构造函数的__super.call(this)以及调用基类方法的laya.ui.Component.prototype.onCompResize.call(this);在2.0是怎么写的 [ 89%]

...有通过一个类的名字(字符串)来获取该类的方法?类似get class by name 问题状态 最新活动: 2019-03-22 17:48 浏览: 810 关注: 1 人

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

18. 关于类中方法的调用 [ 87%]

...ount = function(){         //-----         }     }     Laya.class(FactionListItem,"FactionListItem",FactionMainNodeUI);     return FactionListItem; })();       在一个类里。。我可以用this.这样直接调用方法吗?我现在调用了会报错? 2017-11-27 添加评...

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

19. 1.7.3之后的版本,重复类名出现bug [ 87%]

...下。编译器编译出来,命名的时候都是错乱的 比如: __class(StartUpCommand,'com.game.modules.hall.controller.StartUpCommand',_super); __class(StartUpCommand,'com.game.modules.login.controller.StartUpCommand',_super,'StartUpCommand$1'); __class(StartUpCommand,'com.game.shell.contro...

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

20. Uncaught TypeError: Game.super is not a function [ 87%]

...n var Game = (function(_super){ function Game() { Game.super(this); } Laya.ClassUtils(Game,"Game",_super) return Game; })(ui.GameUI) 2017-10-12 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关的链接 提交 1 个回复 Monica - 知识达人 ...

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