大约有 237 项符合查询结果, 库内数据总量为 30,903 项。 (搜索耗时: 0.0038 秒)
关于js继承类class的参数问题 Laya.class(LoginView, "LoginView", LoginUI) ; // 设置继承关系. 括号里第一个参数是一个方法,第三个是要继承的对象,第二个参数字符串是什么意思啊。 自己写了一个继承,Laya.class(LayaIndex,"LayaIndex",indexUI);...
来源: Laya_社区 发布时间: 20180426
... 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
...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
...博 QZONE 微信 Calvin 赞同来自: 可以证实的,有如下场景: class PageList extends laya.ui.List { constructor() { super(); } protected initialize():void { super.initialize(); this...
来源: Laya_社区 发布时间: 20180810
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
...s.addChild(this.bg2); //创建一个帧循环,更新容器位置 }; Laya.class(BackGround,"BackGround",_super); return BackGround; }(Laya.Sprite));注意: 1、如果_super是传参过来的,直接写_super.call(this)即可,如果不是直接写BackGround.__super(this)即可,两种写法(...
来源: Laya_社区 发布时间: 20170222
...有通过一个类的名字(字符串)来获取该类的方法?类似get class by name 问题状态 最新活动: 2019-03-22 17:48 浏览: 810 关注: 1 人
来源: Laya_社区 发布时间: 20190322
...ount = function(){ //----- } } Laya.class(FactionListItem,"FactionListItem",FactionMainNodeUI); return FactionListItem; })(); 在一个类里。。我可以用this.这样直接调用方法吗?我现在调用了会报错? 2017-11-27 添加评...
来源: Laya_社区 发布时间: 20171127
...下。编译器编译出来,命名的时候都是错乱的 比如: __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
...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