{
  "code": "export default class ShareCanvas {\r\n    constructor() {\r\n        this.width = 0;\r\n        this.height = 0;\r\n        this.shareCanvas = Laya.Browser.window.sharedCanvas;\r\n        this.sprite = new Laya.Sprite();\r\n        this.sprite.zOrder = 1008;\r\n        this.sprite.pos(0, 0);\r\n        this.sprite.cacheAs = \"normal\";\r\n        Laya.stage.addChild(this.sprite);\r\n        this.t2d = new Laya.Texture2D();\r\n        this.tex = new Laya.Texture(this.t2d);\r\n    }\r\n    InitData(w = 720, h = 1559) {\r\n        this.width = Laya.stage.width;\r\n        this.height = Laya.stage.height;\r\n        this.shareCanvas.width = w;\r\n        this.shareCanvas.height = h;\r\n    }\r\n    show() {\r\n        Laya.timer.frameLoop(10, this, this.update);\r\n        this.sprite.visible = true;\r\n    }\r\n    hide() {\r\n        Laya.timer.clear(this, this.update);\r\n        this.sprite.visible = false;\r\n    }\r\n    update() {\r\n        this.drawWebgl();\r\n    }\r\n    drawWebgl() {\r\n        this.t2d.loadImageSource(this.shareCanvas);\r\n        this.tex.setTo(this.t2d);\r\n        this.sprite.graphics.clear();\r\n        this.sprite.graphics.drawTexture(this.tex, 0, 0, this.tex.width, this.tex.height);\r\n    }\r\n    draw2d() {\r\n        this.ctx.drawImage(this.shareCanvas, 0, 0, this.shareCanvas.width, this.shareCanvas.height);\r\n    }\r\n}\r\n",
  "references": [
    "C:/Users/admin/Desktop/runner/src/W_Rank/JionTool.ts"
  ]
}
