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

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

511. 关于屏幕适配的问题(急) [ 78%]

...是通过宽度来缩放, Laya.stage.scaleMode = Laya.Stage.SCALE_FIXED_WIDTH;那就是我只要动态设计panel的宽高即可,但是直接把当前屏幕 Laya.Browser.height赋值给panel的高是不行的,还得*1336/Laya.Browser.width才能做到,想知道这是为什么,我发现Laya...

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

512. LAYAAIR加载SWF无线循环 [ 78%]

...op=false;         //  mc.pos(570,230)             mc.width=1000;             mc.height=700;             mc.on("click", this, onAniClick);                 trace("mcwidth:"+mc.width+"mcheight:"+mc.height);                   ...

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

513. 照着官方文档写的 Dialog 报错? [ 78%]

...e.png"); button.size(50, 50); button.name = Dialog.CLOSE; button.pos(bgImg.width - button.width - 5, 5); dialog.addChild(button); dialog.dragArea = "0,0," + bgImg.width + "," + bgImg.height; dialog.show(); }; } Laya.class(LoadResource, "LoadResource", null);照着官方文档实例, 写了一个...

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

514. Texture.getPixels在手机真机Native环境中会报错 [ 78%]

...发报错!因为是必现所以没有提供DEMO了   getPixels(x, y, width, height) {             if (window.conch) {                 return this._nativeObj.getImageData(x, y, width, height); //this._nativeObj为空!             }       ...

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

515. 仿照laya官方demo做了一个视频播放的UI,为啥在微信里不能用? [ 78%]

....stage.addChild(reference); reference.pos(0, 0); reference.size(Laya.stage.width, Laya.stage.height); reference.graphics.drawRect(0, 0, reference.width, reference.height, "#CCCCCC"); let tipElmt = Laya.Browser.createElement("img"); tipElmt.src = getResURI("ui/guide_tip.png"); tipElmt.style.zInddex =...

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

516. laya.resource.BaseTexture_API3.0 [ 78%]

...Memory height id maxMipmapLevel mipmap mipmapCount obsolute referenceCount width wrapModeU wrapModeV wrapModeW cpuMemory gpuMemory Methods _addReference _clearReference _removeReference _setCPUMemory _setCreateURL _setGPUMemory destroy event gpuCompressFormat hasListener isCreateFromURL off offAll o...

来源: Laya3.0_api 发布时间: 20231115

517. 屏幕适配-缩放-Extract Fit [ 78%]

....rect); this.updateRectPos(); } updateRectPos() { this.rect.x = Laya.stage.width / 2; this.rect.y = Laya.stage.height / 2; } } new SmartScale_Scale_EXTRACT_FIT();module laya { import Sprite = Laya.Sprite; import Stage = Laya.Stage; export class SmartScale_Scale_EXTRACT_FIT { private rect: Sprite; co...

来源: Laya2.0_示例 发布时间: 20260303

518. 屏幕适配-缩放-Show All [ 78%]

....rect); this.updateRectPos(); } updateRectPos() { this.rect.x = Laya.stage.width / 2; this.rect.y = Laya.stage.height / 2; } } new SmartScale_Scale_SHOW_ALL();module laya { import Sprite = Laya.Sprite; import Stage = Laya.Stage; export class SmartScale_Scale_SHOW_ALL { private rect: Sprite; construc...

来源: Laya2.0_示例 发布时间: 20260303

519. laya.utils.Utils [ 78%]

...itDOMElementInArea(dom:Object, coordinateSpace:Sprite, x:Number, y:Number, width:Number, height:Number):void[static] 使DOM元素使用舞台内的某块区域内。 Utils  getGID():int[static] 获取一个全局唯一ID。Utils  getGlobalPosAndScale(sprite:Sprite):Rectangle[static] 计算传入...

来源: laya_api 发布时间: 20170929

520. 【解决】富文本html下划线换行bug [ 78%]

...; graphic.drawLine(words[0].x,firstlineY,words[slsIndex].x+words[slsIndex].width,firstlineY,color,1); let secondLineY = words[slsIndex+1].y + words[slsIndex+1].height; graphic.drawLine(words[slsIndex+1].x,secondLineY,lastWords.x+lastWords.width,secondLineY,color,1); }else{ graphic.drawLine(words[0]....

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