From 8d7930fd0832e27a6802cb9459ed2fb722a822cd Mon Sep 17 00:00:00 2001 From: cebgcontract <99630598+cebgcontract@users.noreply.github.com> Date: Tue, 21 Jun 2022 16:55:44 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E8=8F=9C=E5=8D=95=E5=92=8Cqr?= =?UTF-8?q?=E7=9A=84=E6=98=BE=E7=A4=BA=E6=96=B9=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- assets/comp/wallet/prefab/MenuNode.prefab | 1041 +++++++++++++ .../comp/wallet/prefab/MenuNode.prefab.meta | 7 + assets/comp/wallet/prefab/QrNode.prefab | 415 +++++ assets/comp/wallet/prefab/QrNode.prefab.meta | 7 + .../comp/wallet/scripts/common/WalletEvent.ts | 2 + assets/comp/wallet/scripts/ui/QrNode.ts | 17 + assets/comp/wallet/scripts/ui/QrNode.ts.meta | 9 + assets/comp/wallet/scripts/ui/WalletInfo.ts | 17 +- .../comp/wallet/scripts/ui/WalletMainPanel.ts | 35 +- .../comp/wallet/scripts/ui/comp/QRCodeComp.ts | 10 +- assets/scenes/main.fire | 1347 +---------------- 11 files changed, 1556 insertions(+), 1351 deletions(-) create mode 100644 assets/comp/wallet/prefab/MenuNode.prefab create mode 100644 assets/comp/wallet/prefab/MenuNode.prefab.meta create mode 100644 assets/comp/wallet/prefab/QrNode.prefab create mode 100644 assets/comp/wallet/prefab/QrNode.prefab.meta create mode 100644 assets/comp/wallet/scripts/ui/QrNode.ts create mode 100644 assets/comp/wallet/scripts/ui/QrNode.ts.meta diff --git a/assets/comp/wallet/prefab/MenuNode.prefab b/assets/comp/wallet/prefab/MenuNode.prefab new file mode 100644 index 0000000..9eee8ef --- /dev/null +++ b/assets/comp/wallet/prefab/MenuNode.prefab @@ -0,0 +1,1041 @@ +[ + { + "__type__": "cc.Prefab", + "_name": "", + "_objFlags": 0, + "_native": "", + "data": { + "__id__": 1 + }, + "optimizationPolicy": 0, + "asyncLoadAssets": false + }, + { + "__type__": "cc.Node", + "_name": "MenuNode", + "_objFlags": 0, + "_parent": null, + "_children": [ + { + "__id__": 2 + }, + { + "__id__": 7 + }, + { + "__id__": 10 + }, + { + "__id__": 13 + }, + { + "__id__": 16 + }, + { + "__id__": 19 + }, + { + "__id__": 24 + } + ], + "_active": true, + "_level": 2, + "_components": [ + { + "__id__": 28 + }, + { + "__id__": 29 + } + ], + "_prefab": { + "__id__": 30 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 1024, + "height": 512 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_position": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_scale": { + "__type__": "cc.Vec3", + "x": 1, + "y": 1, + "z": 1 + }, + "_rotationX": 0, + "_rotationY": 0, + "_quat": { + "__type__": "cc.Quat", + "x": 0, + "y": 0, + "z": 0, + "w": 1 + }, + "_skewX": 0, + "_skewY": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Node", + "_name": "New Sprite(Splash)", + "_objFlags": 0, + "_parent": { + "__id__": 1 + }, + "_children": [], + "_active": true, + "_level": 3, + "_components": [ + { + "__id__": 3 + }, + { + "__id__": 4 + }, + { + "__id__": 5 + } + ], + "_prefab": { + "__id__": 6 + }, + "_opacity": 97, + "_color": { + "__type__": "cc.Color", + "r": 0, + "g": 0, + "b": 0, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 1024, + "height": 512 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_position": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_scale": { + "__type__": "cc.Vec3", + "x": 1, + "y": 1, + "z": 1 + }, + "_rotationX": 0, + "_rotationY": 0, + "_quat": { + "__type__": "cc.Quat", + "x": 0, + "y": 0, + "z": 0, + "w": 1 + }, + "_skewX": 0, + "_skewY": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 2 + }, + "_enabled": true, + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "a23235d1-15db-4b95-8439-a2e005bfff91" + }, + "_type": 0, + "_sizeMode": 0, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_state": 0, + "_atlas": null, + "_id": "" + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 2 + }, + "_enabled": true, + "alignMode": 1, + "_target": null, + "_alignFlags": 45, + "_left": 0, + "_right": 0, + "_top": 0, + "_bottom": 0, + "_verticalCenter": 0, + "_horizontalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 100, + "_originalHeight": 100, + "_id": "" + }, + { + "__type__": "cc.BlockInputEvents", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 2 + }, + "_enabled": true, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "e1M0SSz1pCmrMtPVFtJezV", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "bg-blue", + "_objFlags": 0, + "_parent": { + "__id__": 1 + }, + "_children": [], + "_active": false, + "_level": 3, + "_components": [ + { + "__id__": 8 + } + ], + "_prefab": { + "__id__": 9 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 400, + "height": 350 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_position": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_scale": { + "__type__": "cc.Vec3", + "x": 1, + "y": 1, + "z": 1 + }, + "_rotationX": 0, + "_rotationY": 0, + "_quat": { + "__type__": "cc.Quat", + "x": 0, + "y": 0, + "z": 0, + "w": 1 + }, + "_skewX": 0, + "_skewY": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 7 + }, + "_enabled": true, + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "f201fb81-4964-47e4-a820-bececa838851" + }, + "_type": 1, + "_sizeMode": 0, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_state": 0, + "_atlas": null, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "330F7geNVDMbw3FHfRtmS8", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "bar-black", + "_objFlags": 0, + "_parent": { + "__id__": 1 + }, + "_children": [], + "_active": true, + "_level": 3, + "_components": [ + { + "__id__": 11 + } + ], + "_prefab": { + "__id__": 12 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 396, + "height": 35 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_position": { + "__type__": "cc.Vec3", + "x": 0, + "y": 158, + "z": 0 + }, + "_scale": { + "__type__": "cc.Vec3", + "x": 1, + "y": 1, + "z": 1 + }, + "_rotationX": 0, + "_rotationY": 0, + "_quat": { + "__type__": "cc.Quat", + "x": 0, + "y": 0, + "z": 0, + "w": 1 + }, + "_skewX": 0, + "_skewY": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 10 + }, + "_enabled": true, + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "040ee26c-fe0c-4996-a957-4c17cd376ff5" + }, + "_type": 1, + "_sizeMode": 0, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_state": 0, + "_atlas": null, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "cawI/5DfBHM5iufLlNLjvb", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "bar-black", + "_objFlags": 0, + "_parent": { + "__id__": 1 + }, + "_children": [], + "_active": true, + "_level": 3, + "_components": [ + { + "__id__": 14 + } + ], + "_prefab": { + "__id__": 15 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 396, + "height": 35 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_position": { + "__type__": "cc.Vec3", + "x": 0, + "y": -156, + "z": 0 + }, + "_scale": { + "__type__": "cc.Vec3", + "x": 1, + "y": 1, + "z": 1 + }, + "_rotationX": 180, + "_rotationY": 180, + "_quat": { + "__type__": "cc.Quat", + "x": 0, + "y": 0, + "z": -1, + "w": 6.123233995736766e-17 + }, + "_skewX": 0, + "_skewY": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 13 + }, + "_enabled": true, + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "040ee26c-fe0c-4996-a957-4c17cd376ff5" + }, + "_type": 1, + "_sizeMode": 0, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_state": 0, + "_atlas": null, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "f3/WiE/89DCp6WHZ8/xA2o", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "menuPanel", + "_objFlags": 0, + "_parent": { + "__id__": 1 + }, + "_children": [], + "_active": true, + "_level": 3, + "_components": [ + { + "__id__": 17 + } + ], + "_prefab": { + "__id__": 18 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 400, + "height": 350 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_position": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_scale": { + "__type__": "cc.Vec3", + "x": 1, + "y": 1, + "z": 1 + }, + "_rotationX": 0, + "_rotationY": 0, + "_quat": { + "__type__": "cc.Quat", + "x": 0, + "y": 0, + "z": 0, + "w": 1 + }, + "_skewX": 0, + "_skewY": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 16 + }, + "_enabled": true, + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "f8a72ecb-343d-4c53-9429-112006b05c75" + }, + "_type": 1, + "_sizeMode": 0, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_state": 0, + "_atlas": null, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "4fgNRF1L1HabtsBzV9YPqd", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "close", + "_objFlags": 0, + "_parent": { + "__id__": 1 + }, + "_children": [], + "_active": true, + "_level": 3, + "_components": [ + { + "__id__": 20 + }, + { + "__id__": 21 + } + ], + "_prefab": { + "__id__": 23 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 32, + "height": 32 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_position": { + "__type__": "cc.Vec3", + "x": 192, + "y": 171, + "z": 0 + }, + "_scale": { + "__type__": "cc.Vec3", + "x": 1, + "y": 1, + "z": 1 + }, + "_rotationX": 0, + "_rotationY": 0, + "_quat": { + "__type__": "cc.Quat", + "x": 0, + "y": 0, + "z": 0, + "w": 1 + }, + "_skewX": 0, + "_skewY": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 19 + }, + "_enabled": true, + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "94a5022b-77d8-4fca-b843-c7b59add72aa" + }, + "_type": 0, + "_sizeMode": 0, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_state": 0, + "_atlas": null, + "_id": "" + }, + { + "__type__": "cc.Button", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 19 + }, + "_enabled": true, + "duration": 0.1, + "zoomScale": 1.2, + "clickEvents": [ + { + "__id__": 22 + } + ], + "_N$interactable": true, + "_N$enableAutoGrayEffect": false, + "_N$transition": 3, + "transition": 3, + "_N$normalColor": { + "__type__": "cc.Color", + "r": 214, + "g": 214, + "b": 214, + "a": 255 + }, + "_N$pressedColor": { + "__type__": "cc.Color", + "r": 211, + "g": 211, + "b": 211, + "a": 255 + }, + "pressedColor": { + "__type__": "cc.Color", + "r": 211, + "g": 211, + "b": 211, + "a": 255 + }, + "_N$hoverColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "hoverColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$disabledColor": { + "__type__": "cc.Color", + "r": 124, + "g": 124, + "b": 124, + "a": 255 + }, + "_N$normalSprite": null, + "_N$pressedSprite": null, + "pressedSprite": null, + "_N$hoverSprite": null, + "hoverSprite": null, + "_N$disabledSprite": null, + "_N$target": null, + "_id": "" + }, + { + "__type__": "cc.ClickEvent", + "target": { + "__id__": 1 + }, + "component": "", + "_componentId": "f2e85abZ1NDc58oBSrPm057", + "handler": "onCloseClick", + "customEventData": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "488IMbAAdAp4LuudhutDWL", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "contentNode", + "_objFlags": 0, + "_parent": { + "__id__": 1 + }, + "_children": [], + "_active": true, + "_level": 3, + "_components": [ + { + "__id__": 25 + }, + { + "__id__": 26 + } + ], + "_prefab": { + "__id__": 27 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 396, + "height": 280 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_position": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_scale": { + "__type__": "cc.Vec3", + "x": 1, + "y": 1, + "z": 1 + }, + "_rotationX": 0, + "_rotationY": 0, + "_quat": { + "__type__": "cc.Quat", + "x": 0, + "y": 0, + "z": 0, + "w": 1 + }, + "_skewX": 0, + "_skewY": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 24 + }, + "_enabled": true, + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "f201fb81-4964-47e4-a820-bececa838851" + }, + "_type": 1, + "_sizeMode": 0, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_state": 0, + "_atlas": null, + "_id": "" + }, + { + "__type__": "cc.Layout", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 24 + }, + "_enabled": true, + "_layoutSize": { + "__type__": "cc.Size", + "width": 300, + "height": 200 + }, + "_resize": 0, + "_N$layoutType": 3, + "_N$padding": 0, + "_N$cellSize": { + "__type__": "cc.Size", + "width": 90, + "height": 120 + }, + "_N$startAxis": 0, + "_N$paddingLeft": 5, + "_N$paddingRight": 5, + "_N$paddingTop": 5, + "_N$paddingBottom": 5, + "_N$spacingX": 5, + "_N$spacingY": 5, + "_N$verticalDirection": 1, + "_N$horizontalDirection": 0, + "_N$affectedByScale": false, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "1cfDUvpZpELJNYna4AkKOt", + "sync": false + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 1 + }, + "_enabled": true, + "alignMode": 1, + "_target": null, + "_alignFlags": 45, + "_left": 0, + "_right": 0, + "_top": 0, + "_bottom": 0, + "_verticalCenter": 0, + "_horizontalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 0, + "_originalHeight": 0, + "_id": "" + }, + { + "__type__": "f2e85abZ1NDc58oBSrPm057", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 1 + }, + "_enabled": true, + "btnPreb": { + "__uuid__": "edefc8c1-62a6-49f9-8610-13865e5b0e32" + }, + "contentNode": { + "__id__": 24 + }, + "icons": [ + { + "__uuid__": "67fd1c96-89a2-4949-b807-226052342b6c" + }, + { + "__uuid__": "90bf1e2d-12ad-46e5-a4e8-a38ee60dffa4" + }, + { + "__uuid__": "eb181377-d56b-4ee2-b3cc-9ec7367080eb" + }, + { + "__uuid__": "ee2ddc55-f2ed-4cbe-a5cb-0e54b85bf647" + }, + { + "__uuid__": "8917c4b9-d880-44a8-950b-1bea01707e86" + }, + { + "__uuid__": "c2eed000-f86f-4a6b-b25e-338e9e8f012f" + } + ], + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__id__": 0 + }, + "fileId": "263ZmWXZBMaKznay4xGbjg", + "sync": false + } +] \ No newline at end of file diff --git a/assets/comp/wallet/prefab/MenuNode.prefab.meta b/assets/comp/wallet/prefab/MenuNode.prefab.meta new file mode 100644 index 0000000..95dc113 --- /dev/null +++ b/assets/comp/wallet/prefab/MenuNode.prefab.meta @@ -0,0 +1,7 @@ +{ + "ver": "1.0.1", + "uuid": "0bfa7bbc-42ab-4204-9fe7-3cd9b56eb045", + "optimizationPolicy": "AUTO", + "asyncLoadAssets": false, + "subMetas": {} +} \ No newline at end of file diff --git a/assets/comp/wallet/prefab/QrNode.prefab b/assets/comp/wallet/prefab/QrNode.prefab new file mode 100644 index 0000000..b474363 --- /dev/null +++ b/assets/comp/wallet/prefab/QrNode.prefab @@ -0,0 +1,415 @@ +[ + { + "__type__": "cc.Prefab", + "_name": "", + "_objFlags": 0, + "_native": "", + "data": { + "__id__": 1 + }, + "optimizationPolicy": 0, + "asyncLoadAssets": false + }, + { + "__type__": "cc.Node", + "_name": "QrNode", + "_objFlags": 0, + "_parent": null, + "_children": [ + { + "__id__": 2 + }, + { + "__id__": 8 + } + ], + "_active": true, + "_level": 1, + "_components": [ + { + "__id__": 11 + } + ], + "_prefab": { + "__id__": 12 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 1024, + "height": 512 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_position": { + "__type__": "cc.Vec3", + "x": 512, + "y": 256, + "z": 0 + }, + "_scale": { + "__type__": "cc.Vec3", + "x": 1, + "y": 1, + "z": 1 + }, + "_rotationX": 0, + "_rotationY": 0, + "_quat": { + "__type__": "cc.Quat", + "x": 0, + "y": 0, + "z": 0, + "w": 1 + }, + "_skewX": 0, + "_skewY": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Node", + "_name": "New Sprite(Splash)", + "_objFlags": 0, + "_parent": { + "__id__": 1 + }, + "_children": [], + "_active": true, + "_level": 4, + "_components": [ + { + "__id__": 3 + }, + { + "__id__": 4 + }, + { + "__id__": 5 + } + ], + "_prefab": { + "__id__": 7 + }, + "_opacity": 97, + "_color": { + "__type__": "cc.Color", + "r": 0, + "g": 0, + "b": 0, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 1024, + "height": 512 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_position": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_scale": { + "__type__": "cc.Vec3", + "x": 1, + "y": 1, + "z": 1 + }, + "_rotationX": 0, + "_rotationY": 0, + "_quat": { + "__type__": "cc.Quat", + "x": 0, + "y": 0, + "z": 0, + "w": 1 + }, + "_skewX": 0, + "_skewY": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "cc.Sprite", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 2 + }, + "_enabled": true, + "_srcBlendFactor": 770, + "_dstBlendFactor": 771, + "_spriteFrame": { + "__uuid__": "a23235d1-15db-4b95-8439-a2e005bfff91" + }, + "_type": 0, + "_sizeMode": 0, + "_fillType": 0, + "_fillCenter": { + "__type__": "cc.Vec2", + "x": 0, + "y": 0 + }, + "_fillStart": 0, + "_fillRange": 0, + "_isTrimmedMode": true, + "_state": 0, + "_atlas": null, + "_id": "" + }, + { + "__type__": "cc.Widget", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 2 + }, + "_enabled": true, + "alignMode": 1, + "_target": null, + "_alignFlags": 45, + "_left": 0, + "_right": 0, + "_top": 0, + "_bottom": 0, + "_verticalCenter": 0, + "_horizontalCenter": 0, + "_isAbsLeft": true, + "_isAbsRight": true, + "_isAbsTop": true, + "_isAbsBottom": true, + "_isAbsHorizontalCenter": true, + "_isAbsVerticalCenter": true, + "_originalWidth": 100, + "_originalHeight": 100, + "_id": "" + }, + { + "__type__": "cc.Button", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 2 + }, + "_enabled": true, + "duration": 0.1, + "zoomScale": 1.2, + "clickEvents": [ + { + "__id__": 6 + } + ], + "_N$interactable": true, + "_N$enableAutoGrayEffect": false, + "_N$transition": 0, + "transition": 0, + "_N$normalColor": { + "__type__": "cc.Color", + "r": 214, + "g": 214, + "b": 214, + "a": 255 + }, + "_N$pressedColor": { + "__type__": "cc.Color", + "r": 211, + "g": 211, + "b": 211, + "a": 255 + }, + "pressedColor": { + "__type__": "cc.Color", + "r": 211, + "g": 211, + "b": 211, + "a": 255 + }, + "_N$hoverColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "hoverColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_N$disabledColor": { + "__type__": "cc.Color", + "r": 124, + "g": 124, + "b": 124, + "a": 255 + }, + "_N$normalSprite": null, + "_N$pressedSprite": null, + "pressedSprite": null, + "_N$hoverSprite": null, + "hoverSprite": null, + "_N$disabledSprite": null, + "_N$target": null, + "_id": "" + }, + { + "__type__": "cc.ClickEvent", + "target": { + "__id__": 1 + }, + "component": "", + "_componentId": "287f2RBg4FGULo0MNLU+fmM", + "handler": "hideMe", + "customEventData": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__uuid__": "0f14a371-be16-44a1-adcf-319d54c7ba3d" + }, + "fileId": "892rmrF1lJTpW9wI5hBgto", + "sync": false + }, + { + "__type__": "cc.Node", + "_name": "qrImgNode", + "_objFlags": 0, + "_parent": { + "__id__": 1 + }, + "_children": [], + "_active": true, + "_level": 4, + "_components": [ + { + "__id__": 9 + } + ], + "_prefab": { + "__id__": 10 + }, + "_opacity": 255, + "_color": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "_contentSize": { + "__type__": "cc.Size", + "width": 300, + "height": 300 + }, + "_anchorPoint": { + "__type__": "cc.Vec2", + "x": 0.5, + "y": 0.5 + }, + "_position": { + "__type__": "cc.Vec3", + "x": 0, + "y": 0, + "z": 0 + }, + "_scale": { + "__type__": "cc.Vec3", + "x": 1, + "y": 1, + "z": 1 + }, + "_rotationX": 0, + "_rotationY": 0, + "_quat": { + "__type__": "cc.Quat", + "x": 0, + "y": 0, + "z": 0, + "w": 1 + }, + "_skewX": 0, + "_skewY": 0, + "groupIndex": 0, + "_id": "" + }, + { + "__type__": "360a3jV8pdLLaS9OFBYhZwv", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 8 + }, + "_enabled": true, + "lightColor": { + "__type__": "cc.Color", + "r": 255, + "g": 255, + "b": 255, + "a": 255 + }, + "deepColor": { + "__type__": "cc.Color", + "r": 0, + "g": 0, + "b": 0, + "a": 255 + }, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__uuid__": "0f14a371-be16-44a1-adcf-319d54c7ba3d" + }, + "fileId": "7fdBt6xvJCbZha0tOFrOnZ", + "sync": false + }, + { + "__type__": "287f2RBg4FGULo0MNLU+fmM", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 1 + }, + "_enabled": true, + "qrComp": { + "__id__": 9 + }, + "_id": "" + }, + { + "__type__": "cc.PrefabInfo", + "root": { + "__id__": 1 + }, + "asset": { + "__uuid__": "0f14a371-be16-44a1-adcf-319d54c7ba3d" + }, + "fileId": "60aR5zcbNMJKABPX77Q5lw", + "sync": false + } +] \ No newline at end of file diff --git a/assets/comp/wallet/prefab/QrNode.prefab.meta b/assets/comp/wallet/prefab/QrNode.prefab.meta new file mode 100644 index 0000000..31d41aa --- /dev/null +++ b/assets/comp/wallet/prefab/QrNode.prefab.meta @@ -0,0 +1,7 @@ +{ + "ver": "1.0.1", + "uuid": "0f14a371-be16-44a1-adcf-319d54c7ba3d", + "optimizationPolicy": "AUTO", + "asyncLoadAssets": false, + "subMetas": {} +} \ No newline at end of file diff --git a/assets/comp/wallet/scripts/common/WalletEvent.ts b/assets/comp/wallet/scripts/common/WalletEvent.ts index 9a49f9d..b9e1e8c 100644 --- a/assets/comp/wallet/scripts/common/WalletEvent.ts +++ b/assets/comp/wallet/scripts/common/WalletEvent.ts @@ -22,3 +22,5 @@ export const WALLET_CHAIN_CHANGE = 'wallet_chain_change' export const WALLET_ACCOUNT_CHANGE = 'wallet_account_change' export const WALLET_TOKEN_TYPE_CHANGE = 'wallet_token_type_change' + +export const WALLET_SHOW_QR = 'wallet_show_qr' diff --git a/assets/comp/wallet/scripts/ui/QrNode.ts b/assets/comp/wallet/scripts/ui/QrNode.ts new file mode 100644 index 0000000..c10ba2b --- /dev/null +++ b/assets/comp/wallet/scripts/ui/QrNode.ts @@ -0,0 +1,17 @@ +import QRCodeComp from "./comp/QRCodeComp"; + +const {ccclass, property} = cc._decorator; + +@ccclass +export default class QrNode extends cc.Component { + @property(QRCodeComp) + qrComp: QRCodeComp = null + + showQr(val: string) { + this.qrComp.renderQr(val) + } + + hideMe() { + this.node.active = false + } +} \ No newline at end of file diff --git a/assets/comp/wallet/scripts/ui/QrNode.ts.meta b/assets/comp/wallet/scripts/ui/QrNode.ts.meta new file mode 100644 index 0000000..ad45e62 --- /dev/null +++ b/assets/comp/wallet/scripts/ui/QrNode.ts.meta @@ -0,0 +1,9 @@ +{ + "ver": "1.0.5", + "uuid": "287f2441-8381-4650-ba34-30d2d4f9f98c", + "isPlugin": false, + "loadPluginInWeb": true, + "loadPluginInNative": true, + "loadPluginInEditor": false, + "subMetas": {} +} \ No newline at end of file diff --git a/assets/comp/wallet/scripts/ui/WalletInfo.ts b/assets/comp/wallet/scripts/ui/WalletInfo.ts index 661ee7c..e2c6f27 100644 --- a/assets/comp/wallet/scripts/ui/WalletInfo.ts +++ b/assets/comp/wallet/scripts/ui/WalletInfo.ts @@ -1,5 +1,5 @@ import { formatPrice } from "../common/chain.util"; -import { WALLET_CHAIN_CHANGE } from "../common/WalletEvent"; +import { WALLET_CHAIN_CHANGE, WALLET_SHOW_QR } from "../common/WalletEvent"; import { Bind } from "../decorator/AutoUpdateUI"; import JCWallet, { IChainData } from "../JCWallet"; import { renderFromTokenMinimalUnit } from "../util/number.util"; @@ -18,15 +18,14 @@ export default class WalletInfo extends WalletBase { @property(cc.Label) balanceLabel: cc.Label = null; - @property(cc.Node) - qrNode: cc.Node = null; - @property(HashIcon) avatar: HashIcon = null; accountId: string = ''; balance: string = '' + @property(cc.Node) + parentNode: cc.Node = null // LIFE-CYCLE CALLBACKS: @@ -87,13 +86,7 @@ export default class WalletInfo extends WalletBase { const address = this.wallet.currentAccount().address const chainId = this.wallet.currentChain.id let qrUrl = `ethereum:${address}@${chainId}` - this.showQr(qrUrl) - } - hideQr() { - this.qrNode.active = false - } - showQr(val: string) { - this.qrNode.active = true - this.qrNode.getChildByName('qrImgNode').getComponent('QRCodeComp').showQr(val) + // this.showQr(qrUrl) + this.wallet.mainHandlers.emit(WALLET_SHOW_QR, qrUrl) } } diff --git a/assets/comp/wallet/scripts/ui/WalletMainPanel.ts b/assets/comp/wallet/scripts/ui/WalletMainPanel.ts index 27b76c9..c21f285 100644 --- a/assets/comp/wallet/scripts/ui/WalletMainPanel.ts +++ b/assets/comp/wallet/scripts/ui/WalletMainPanel.ts @@ -1,3 +1,4 @@ +import { WALLET_SHOW_QR } from "../common/WalletEvent"; import JCWallet from "../JCWallet"; import ChainTab from "./ChainTab"; import ListNode from "./ListNode"; @@ -18,8 +19,14 @@ export default class WalletMainPanel extends WalletBase { }) listNode: ListNode = null - @property(cc.Node) - menuPanel: cc.Node = null + @property(cc.Prefab) + menuPreb: cc.Prefab = null + + @property(cc.Prefab) + qrPreb: cc.Prefab = null + + subNodeMap: Map = new Map() + // LIFE-CYCLE CALLBACKS: @@ -27,10 +34,11 @@ export default class WalletMainPanel extends WalletBase { start () { super.start() + this.wallet.mainHandlers.on(WALLET_SHOW_QR, this.showQrNode.bind(this)) } // update (dt) {} - + hideWallet() { this.node.active = false } @@ -44,8 +52,27 @@ export default class WalletMainPanel extends WalletBase { } } + private fetchNode(tag: string, preb: cc.Prefab) { + if (!this.subNodeMap.has(tag)) { + const node = cc.instantiate(preb) + node.x = 0 + node.y = 0 + this.node.addChild(node) + this.subNodeMap.set(tag, node) + } + return this.subNodeMap.get(tag) + } onMenuClick() { - this.menuPanel.active = true + const tag = 'menu-node' + const node = this.fetchNode(tag, this.menuPreb) + node.active = true + } + + showQrNode(val: string) { + const tag = 'qr-node' + const node = this.fetchNode(tag, this.qrPreb) + node.getComponent('QrNode').showQr(val) + node.active = true } } diff --git a/assets/comp/wallet/scripts/ui/comp/QRCodeComp.ts b/assets/comp/wallet/scripts/ui/comp/QRCodeComp.ts index 3d47a10..4444408 100644 --- a/assets/comp/wallet/scripts/ui/comp/QRCodeComp.ts +++ b/assets/comp/wallet/scripts/ui/comp/QRCodeComp.ts @@ -4,13 +4,9 @@ import { QR } from '../../lib/qrcode'; @ccclass export default class QRCodeComp extends cc.Component { - @property({ - type: cc.Color - }) + @property(cc.Color) lightColor: cc.Color = cc.Color.WHITE - @property({ - type: cc.Color - }) + @property(cc.Color) deepColor: cc.Color = cc.Color.BLACK preVal:string = '' @@ -24,7 +20,7 @@ export default class QRCodeComp extends cc.Component { } // update (dt) {} - showQr(val: string) { + renderQr(val: string) { if (this.preVal === val) { return } diff --git a/assets/scenes/main.fire b/assets/scenes/main.fire index 144f53c..6cf82fc 100644 --- a/assets/scenes/main.fire +++ b/assets/scenes/main.fire @@ -17,7 +17,7 @@ "__id__": 2 }, { - "__id__": 218 + "__id__": 187 } ], "_active": false, @@ -87,13 +87,13 @@ "_level": 1, "_components": [ { - "__id__": 215 + "__id__": 184 }, { - "__id__": 216 + "__id__": 185 }, { - "__id__": 219 + "__id__": 188 } ], "_prefab": null, @@ -4645,22 +4645,19 @@ }, { "__id__": 145 - }, - { - "__id__": 190 } ], "_active": true, "_level": 1, "_components": [ { - "__id__": 212 + "__id__": 181 }, { - "__id__": 213 + "__id__": 182 }, { - "__id__": 214 + "__id__": 183 } ], "_prefab": null, @@ -6349,19 +6346,16 @@ }, { "__id__": 177 - }, - { - "__id__": 179 } ], "_active": true, "_level": 2, "_components": [ { - "__id__": 188 + "__id__": 179 }, { - "__id__": 189 + "__id__": 180 } ], "_prefab": null, @@ -7821,385 +7815,6 @@ "_N$cacheMode": 0, "_id": "3ewsJywWVKmalvX+ESCiV+" }, - { - "__type__": "cc.Node", - "_name": "qrNode", - "_objFlags": 0, - "_parent": { - "__id__": 145 - }, - "_children": [ - { - "__id__": 180 - }, - { - "__id__": 185 - } - ], - "_active": false, - "_level": 3, - "_components": [ - { - "__id__": 187 - } - ], - "_prefab": null, - "_opacity": 255, - "_color": { - "__type__": "cc.Color", - "r": 255, - "g": 255, - "b": 255, - "a": 255 - }, - "_contentSize": { - "__type__": "cc.Size", - "width": 1024, - "height": 512 - }, - "_anchorPoint": { - "__type__": "cc.Vec2", - "x": 0.5, - "y": 0.5 - }, - "_position": { - "__type__": "cc.Vec3", - "x": 0, - "y": 0, - "z": 0 - }, - "_scale": { - "__type__": "cc.Vec3", - "x": 1, - "y": 1, - "z": 1 - }, - "_rotationX": 0, - "_rotationY": 0, - "_quat": { - "__type__": "cc.Quat", - "x": 0, - "y": 0, - "z": 0, - "w": 1 - }, - "_skewX": 0, - "_skewY": 0, - "groupIndex": 0, - "_id": "60aR5zcbNMJKABPX77Q5lw" - }, - { - "__type__": "cc.Node", - "_name": "New Sprite(Splash)", - "_objFlags": 0, - "_parent": { - "__id__": 179 - }, - "_children": [], - "_active": true, - "_level": 4, - "_components": [ - { - "__id__": 181 - }, - { - "__id__": 182 - }, - { - "__id__": 183 - } - ], - "_prefab": null, - "_opacity": 97, - "_color": { - "__type__": "cc.Color", - "r": 0, - "g": 0, - "b": 0, - "a": 255 - }, - "_contentSize": { - "__type__": "cc.Size", - "width": 1024, - "height": 512 - }, - "_anchorPoint": { - "__type__": "cc.Vec2", - "x": 0.5, - "y": 0.5 - }, - "_position": { - "__type__": "cc.Vec3", - "x": 0, - "y": 0, - "z": 0 - }, - "_scale": { - "__type__": "cc.Vec3", - "x": 1, - "y": 1, - "z": 1 - }, - "_rotationX": 0, - "_rotationY": 0, - "_quat": { - "__type__": "cc.Quat", - "x": 0, - "y": 0, - "z": 0, - "w": 1 - }, - "_skewX": 0, - "_skewY": 0, - "groupIndex": 0, - "_id": "892rmrF1lJTpW9wI5hBgto" - }, - { - "__type__": "cc.Sprite", - "_name": "", - "_objFlags": 0, - "node": { - "__id__": 180 - }, - "_enabled": true, - "_srcBlendFactor": 770, - "_dstBlendFactor": 771, - "_spriteFrame": { - "__uuid__": "a23235d1-15db-4b95-8439-a2e005bfff91" - }, - "_type": 0, - "_sizeMode": 0, - "_fillType": 0, - "_fillCenter": { - "__type__": "cc.Vec2", - "x": 0, - "y": 0 - }, - "_fillStart": 0, - "_fillRange": 0, - "_isTrimmedMode": true, - "_state": 0, - "_atlas": null, - "_id": "cbLMFsaaRA0oOO76Y/eSs0" - }, - { - "__type__": "cc.Widget", - "_name": "", - "_objFlags": 0, - "node": { - "__id__": 180 - }, - "_enabled": true, - "alignMode": 1, - "_target": null, - "_alignFlags": 45, - "_left": 0, - "_right": 0, - "_top": 0, - "_bottom": 0, - "_verticalCenter": 0, - "_horizontalCenter": 0, - "_isAbsLeft": true, - "_isAbsRight": true, - "_isAbsTop": true, - "_isAbsBottom": true, - "_isAbsHorizontalCenter": true, - "_isAbsVerticalCenter": true, - "_originalWidth": 100, - "_originalHeight": 100, - "_id": "5az2KmSe5GEoI8BoMS3fki" - }, - { - "__type__": "cc.Button", - "_name": "", - "_objFlags": 0, - "node": { - "__id__": 180 - }, - "_enabled": true, - "duration": 0.1, - "zoomScale": 1.2, - "clickEvents": [ - { - "__id__": 184 - } - ], - "_N$interactable": true, - "_N$enableAutoGrayEffect": false, - "_N$transition": 0, - "transition": 0, - "_N$normalColor": { - "__type__": "cc.Color", - "r": 214, - "g": 214, - "b": 214, - "a": 255 - }, - "_N$pressedColor": { - "__type__": "cc.Color", - "r": 211, - "g": 211, - "b": 211, - "a": 255 - }, - "pressedColor": { - "__type__": "cc.Color", - "r": 211, - "g": 211, - "b": 211, - "a": 255 - }, - "_N$hoverColor": { - "__type__": "cc.Color", - "r": 255, - "g": 255, - "b": 255, - "a": 255 - }, - "hoverColor": { - "__type__": "cc.Color", - "r": 255, - "g": 255, - "b": 255, - "a": 255 - }, - "_N$disabledColor": { - "__type__": "cc.Color", - "r": 124, - "g": 124, - "b": 124, - "a": 255 - }, - "_N$normalSprite": null, - "_N$pressedSprite": null, - "pressedSprite": null, - "_N$hoverSprite": null, - "hoverSprite": null, - "_N$disabledSprite": null, - "_N$target": null, - "_id": "32KpGEzatOdo4BYRj8vCZP" - }, - { - "__type__": "cc.ClickEvent", - "target": { - "__id__": 145 - }, - "component": "", - "_componentId": "3fe0aN9jsFD57pMhFser+jv", - "handler": "hideQr", - "customEventData": "" - }, - { - "__type__": "cc.Node", - "_name": "qrImgNode", - "_objFlags": 0, - "_parent": { - "__id__": 179 - }, - "_children": [], - "_active": true, - "_level": 4, - "_components": [ - { - "__id__": 186 - } - ], - "_prefab": null, - "_opacity": 255, - "_color": { - "__type__": "cc.Color", - "r": 255, - "g": 255, - "b": 255, - "a": 255 - }, - "_contentSize": { - "__type__": "cc.Size", - "width": 300, - "height": 300 - }, - "_anchorPoint": { - "__type__": "cc.Vec2", - "x": 0.5, - "y": 0.5 - }, - "_position": { - "__type__": "cc.Vec3", - "x": 0, - "y": 0, - "z": 0 - }, - "_scale": { - "__type__": "cc.Vec3", - "x": 1, - "y": 1, - "z": 1 - }, - "_rotationX": 0, - "_rotationY": 0, - "_quat": { - "__type__": "cc.Quat", - "x": 0, - "y": 0, - "z": 0, - "w": 1 - }, - "_skewX": 0, - "_skewY": 0, - "groupIndex": 0, - "_id": "7fdBt6xvJCbZha0tOFrOnZ" - }, - { - "__type__": "360a3jV8pdLLaS9OFBYhZwv", - "_name": "", - "_objFlags": 0, - "node": { - "__id__": 185 - }, - "_enabled": true, - "lightColor": { - "__type__": "cc.Color", - "r": 255, - "g": 255, - "b": 255, - "a": 255 - }, - "deepColor": { - "__type__": "cc.Color", - "r": 0, - "g": 0, - "b": 0, - "a": 255 - }, - "_id": "e4YMROMI1JbYxyWS/wEDfk" - }, - { - "__type__": "cc.Widget", - "_name": "", - "_objFlags": 0, - "node": { - "__id__": 179 - }, - "_enabled": true, - "alignMode": 1, - "_target": null, - "_alignFlags": 45, - "_left": 0, - "_right": 0, - "_top": 0, - "_bottom": 0, - "_verticalCenter": 0, - "_horizontalCenter": 0, - "_isAbsLeft": true, - "_isAbsRight": true, - "_isAbsTop": true, - "_isAbsBottom": true, - "_isAbsHorizontalCenter": true, - "_isAbsVerticalCenter": true, - "_originalWidth": 0, - "_originalHeight": 0, - "_id": "00EGUklFtFfZ2JkHV1Cnfp" - }, { "__type__": "cc.Widget", "_name": "", @@ -8241,940 +7856,12 @@ "balanceLabel": { "__id__": 172 }, - "qrNode": { - "__id__": 179 - }, + "qrNode": null, "avatar": { "__id__": 148 }, "_id": "8bO0XBvlFDPJ87FOgdOxUH" }, - { - "__type__": "cc.Node", - "_name": "menuNode", - "_objFlags": 0, - "_parent": { - "__id__": 102 - }, - "_children": [ - { - "__id__": 191 - }, - { - "__id__": 195 - }, - { - "__id__": 197 - }, - { - "__id__": 199 - }, - { - "__id__": 201 - }, - { - "__id__": 203 - }, - { - "__id__": 207 - } - ], - "_active": false, - "_level": 2, - "_components": [ - { - "__id__": 210 - }, - { - "__id__": 211 - } - ], - "_prefab": null, - "_opacity": 255, - "_color": { - "__type__": "cc.Color", - "r": 255, - "g": 255, - "b": 255, - "a": 255 - }, - "_contentSize": { - "__type__": "cc.Size", - "width": 1024, - "height": 512 - }, - "_anchorPoint": { - "__type__": "cc.Vec2", - "x": 0.5, - "y": 0.5 - }, - "_position": { - "__type__": "cc.Vec3", - "x": 0, - "y": 0, - "z": 0 - }, - "_scale": { - "__type__": "cc.Vec3", - "x": 1, - "y": 1, - "z": 1 - }, - "_rotationX": 0, - "_rotationY": 0, - "_quat": { - "__type__": "cc.Quat", - "x": 0, - "y": 0, - "z": 0, - "w": 1 - }, - "_skewX": 0, - "_skewY": 0, - "groupIndex": 0, - "_id": "263ZmWXZBMaKznay4xGbjg" - }, - { - "__type__": "cc.Node", - "_name": "New Sprite(Splash)", - "_objFlags": 0, - "_parent": { - "__id__": 190 - }, - "_children": [], - "_active": true, - "_level": 3, - "_components": [ - { - "__id__": 192 - }, - { - "__id__": 193 - }, - { - "__id__": 194 - } - ], - "_prefab": null, - "_opacity": 97, - "_color": { - "__type__": "cc.Color", - "r": 0, - "g": 0, - "b": 0, - "a": 255 - }, - "_contentSize": { - "__type__": "cc.Size", - "width": 1024, - "height": 512 - }, - "_anchorPoint": { - "__type__": "cc.Vec2", - "x": 0.5, - "y": 0.5 - }, - "_position": { - "__type__": "cc.Vec3", - "x": 0, - "y": 0, - "z": 0 - }, - "_scale": { - "__type__": "cc.Vec3", - "x": 1, - "y": 1, - "z": 1 - }, - "_rotationX": 0, - "_rotationY": 0, - "_quat": { - "__type__": "cc.Quat", - "x": 0, - "y": 0, - "z": 0, - "w": 1 - }, - "_skewX": 0, - "_skewY": 0, - "groupIndex": 0, - "_id": "e1M0SSz1pCmrMtPVFtJezV" - }, - { - "__type__": "cc.Sprite", - "_name": "", - "_objFlags": 0, - "node": { - "__id__": 191 - }, - "_enabled": true, - "_srcBlendFactor": 770, - "_dstBlendFactor": 771, - "_spriteFrame": { - "__uuid__": "a23235d1-15db-4b95-8439-a2e005bfff91" - }, - "_type": 0, - "_sizeMode": 0, - "_fillType": 0, - "_fillCenter": { - "__type__": "cc.Vec2", - "x": 0, - "y": 0 - }, - "_fillStart": 0, - "_fillRange": 0, - "_isTrimmedMode": true, - "_state": 0, - "_atlas": null, - "_id": "327aZwsXVEnZlHroHADalI" - }, - { - "__type__": "cc.Widget", - "_name": "", - "_objFlags": 0, - "node": { - "__id__": 191 - }, - "_enabled": true, - "alignMode": 1, - "_target": null, - "_alignFlags": 45, - "_left": 0, - "_right": 0, - "_top": 0, - "_bottom": 0, - "_verticalCenter": 0, - "_horizontalCenter": 0, - "_isAbsLeft": true, - "_isAbsRight": true, - "_isAbsTop": true, - "_isAbsBottom": true, - "_isAbsHorizontalCenter": true, - "_isAbsVerticalCenter": true, - "_originalWidth": 100, - "_originalHeight": 100, - "_id": "4eGUTXNm5HTLjeinqi3SpS" - }, - { - "__type__": "cc.BlockInputEvents", - "_name": "", - "_objFlags": 0, - "node": { - "__id__": 191 - }, - "_enabled": true, - "_id": "d5s8l9cvFDWo/fNwOpa2aV" - }, - { - "__type__": "cc.Node", - "_name": "bg-blue", - "_objFlags": 0, - "_parent": { - "__id__": 190 - }, - "_children": [], - "_active": false, - "_level": 3, - "_components": [ - { - "__id__": 196 - } - ], - "_prefab": null, - "_opacity": 255, - "_color": { - "__type__": "cc.Color", - "r": 255, - "g": 255, - "b": 255, - "a": 255 - }, - "_contentSize": { - "__type__": "cc.Size", - "width": 400, - "height": 350 - }, - "_anchorPoint": { - "__type__": "cc.Vec2", - "x": 0.5, - "y": 0.5 - }, - "_position": { - "__type__": "cc.Vec3", - "x": 0, - "y": 0, - "z": 0 - }, - "_scale": { - "__type__": "cc.Vec3", - "x": 1, - "y": 1, - "z": 1 - }, - "_rotationX": 0, - "_rotationY": 0, - "_quat": { - "__type__": "cc.Quat", - "x": 0, - "y": 0, - "z": 0, - "w": 1 - }, - "_skewX": 0, - "_skewY": 0, - "groupIndex": 0, - "_id": "330F7geNVDMbw3FHfRtmS8" - }, - { - "__type__": "cc.Sprite", - "_name": "", - "_objFlags": 0, - "node": { - "__id__": 195 - }, - "_enabled": true, - "_srcBlendFactor": 770, - "_dstBlendFactor": 771, - "_spriteFrame": { - "__uuid__": "f201fb81-4964-47e4-a820-bececa838851" - }, - "_type": 1, - "_sizeMode": 0, - "_fillType": 0, - "_fillCenter": { - "__type__": "cc.Vec2", - "x": 0, - "y": 0 - }, - "_fillStart": 0, - "_fillRange": 0, - "_isTrimmedMode": true, - "_state": 0, - "_atlas": null, - "_id": "be768t0LZCzqPOb0jHx0QB" - }, - { - "__type__": "cc.Node", - "_name": "bar-black", - "_objFlags": 0, - "_parent": { - "__id__": 190 - }, - "_children": [], - "_active": true, - "_level": 3, - "_components": [ - { - "__id__": 198 - } - ], - "_prefab": null, - "_opacity": 255, - "_color": { - "__type__": "cc.Color", - "r": 255, - "g": 255, - "b": 255, - "a": 255 - }, - "_contentSize": { - "__type__": "cc.Size", - "width": 396, - "height": 35 - }, - "_anchorPoint": { - "__type__": "cc.Vec2", - "x": 0.5, - "y": 0.5 - }, - "_position": { - "__type__": "cc.Vec3", - "x": 0, - "y": 158, - "z": 0 - }, - "_scale": { - "__type__": "cc.Vec3", - "x": 1, - "y": 1, - "z": 1 - }, - "_rotationX": 0, - "_rotationY": 0, - "_quat": { - "__type__": "cc.Quat", - "x": 0, - "y": 0, - "z": 0, - "w": 1 - }, - "_skewX": 0, - "_skewY": 0, - "groupIndex": 0, - "_id": "cawI/5DfBHM5iufLlNLjvb" - }, - { - "__type__": "cc.Sprite", - "_name": "", - "_objFlags": 0, - "node": { - "__id__": 197 - }, - "_enabled": true, - "_srcBlendFactor": 770, - "_dstBlendFactor": 771, - "_spriteFrame": { - "__uuid__": "040ee26c-fe0c-4996-a957-4c17cd376ff5" - }, - "_type": 1, - "_sizeMode": 0, - "_fillType": 0, - "_fillCenter": { - "__type__": "cc.Vec2", - "x": 0, - "y": 0 - }, - "_fillStart": 0, - "_fillRange": 0, - "_isTrimmedMode": true, - "_state": 0, - "_atlas": null, - "_id": "12p22ss9BGI6M2dtX1p4bq" - }, - { - "__type__": "cc.Node", - "_name": "bar-black", - "_objFlags": 0, - "_parent": { - "__id__": 190 - }, - "_children": [], - "_active": true, - "_level": 3, - "_components": [ - { - "__id__": 200 - } - ], - "_prefab": null, - "_opacity": 255, - "_color": { - "__type__": "cc.Color", - "r": 255, - "g": 255, - "b": 255, - "a": 255 - }, - "_contentSize": { - "__type__": "cc.Size", - "width": 396, - "height": 35 - }, - "_anchorPoint": { - "__type__": "cc.Vec2", - "x": 0.5, - "y": 0.5 - }, - "_position": { - "__type__": "cc.Vec3", - "x": 0, - "y": -156, - "z": 0 - }, - "_scale": { - "__type__": "cc.Vec3", - "x": 1, - "y": 1, - "z": 1 - }, - "_rotationX": 180, - "_rotationY": 180, - "_quat": { - "__type__": "cc.Quat", - "x": 0, - "y": 0, - "z": -1, - "w": 6.123233995736766e-17 - }, - "_skewX": 0, - "_skewY": 0, - "groupIndex": 0, - "_id": "f3/WiE/89DCp6WHZ8/xA2o" - }, - { - "__type__": "cc.Sprite", - "_name": "", - "_objFlags": 0, - "node": { - "__id__": 199 - }, - "_enabled": true, - "_srcBlendFactor": 770, - "_dstBlendFactor": 771, - "_spriteFrame": { - "__uuid__": "040ee26c-fe0c-4996-a957-4c17cd376ff5" - }, - "_type": 1, - "_sizeMode": 0, - "_fillType": 0, - "_fillCenter": { - "__type__": "cc.Vec2", - "x": 0, - "y": 0 - }, - "_fillStart": 0, - "_fillRange": 0, - "_isTrimmedMode": true, - "_state": 0, - "_atlas": null, - "_id": "d9+13UJf1PDoX9w+EZDfSE" - }, - { - "__type__": "cc.Node", - "_name": "menuPanel", - "_objFlags": 0, - "_parent": { - "__id__": 190 - }, - "_children": [], - "_active": true, - "_level": 3, - "_components": [ - { - "__id__": 202 - } - ], - "_prefab": null, - "_opacity": 255, - "_color": { - "__type__": "cc.Color", - "r": 255, - "g": 255, - "b": 255, - "a": 255 - }, - "_contentSize": { - "__type__": "cc.Size", - "width": 400, - "height": 350 - }, - "_anchorPoint": { - "__type__": "cc.Vec2", - "x": 0.5, - "y": 0.5 - }, - "_position": { - "__type__": "cc.Vec3", - "x": 0, - "y": 0, - "z": 0 - }, - "_scale": { - "__type__": "cc.Vec3", - "x": 1, - "y": 1, - "z": 1 - }, - "_rotationX": 0, - "_rotationY": 0, - "_quat": { - "__type__": "cc.Quat", - "x": 0, - "y": 0, - "z": 0, - "w": 1 - }, - "_skewX": 0, - "_skewY": 0, - "groupIndex": 0, - "_id": "4fgNRF1L1HabtsBzV9YPqd" - }, - { - "__type__": "cc.Sprite", - "_name": "", - "_objFlags": 0, - "node": { - "__id__": 201 - }, - "_enabled": true, - "_srcBlendFactor": 770, - "_dstBlendFactor": 771, - "_spriteFrame": { - "__uuid__": "f8a72ecb-343d-4c53-9429-112006b05c75" - }, - "_type": 1, - "_sizeMode": 0, - "_fillType": 0, - "_fillCenter": { - "__type__": "cc.Vec2", - "x": 0, - "y": 0 - }, - "_fillStart": 0, - "_fillRange": 0, - "_isTrimmedMode": true, - "_state": 0, - "_atlas": null, - "_id": "d9jL0VT71BWo+aX9/rR7Pv" - }, - { - "__type__": "cc.Node", - "_name": "close", - "_objFlags": 0, - "_parent": { - "__id__": 190 - }, - "_children": [], - "_active": true, - "_level": 3, - "_components": [ - { - "__id__": 204 - }, - { - "__id__": 205 - } - ], - "_prefab": null, - "_opacity": 255, - "_color": { - "__type__": "cc.Color", - "r": 255, - "g": 255, - "b": 255, - "a": 255 - }, - "_contentSize": { - "__type__": "cc.Size", - "width": 32, - "height": 32 - }, - "_anchorPoint": { - "__type__": "cc.Vec2", - "x": 0.5, - "y": 0.5 - }, - "_position": { - "__type__": "cc.Vec3", - "x": 192, - "y": 171, - "z": 0 - }, - "_scale": { - "__type__": "cc.Vec3", - "x": 1, - "y": 1, - "z": 1 - }, - "_rotationX": 0, - "_rotationY": 0, - "_quat": { - "__type__": "cc.Quat", - "x": 0, - "y": 0, - "z": 0, - "w": 1 - }, - "_skewX": 0, - "_skewY": 0, - "groupIndex": 0, - "_id": "488IMbAAdAp4LuudhutDWL" - }, - { - "__type__": "cc.Sprite", - "_name": "", - "_objFlags": 0, - "node": { - "__id__": 203 - }, - "_enabled": true, - "_srcBlendFactor": 770, - "_dstBlendFactor": 771, - "_spriteFrame": { - "__uuid__": "94a5022b-77d8-4fca-b843-c7b59add72aa" - }, - "_type": 0, - "_sizeMode": 0, - "_fillType": 0, - "_fillCenter": { - "__type__": "cc.Vec2", - "x": 0, - "y": 0 - }, - "_fillStart": 0, - "_fillRange": 0, - "_isTrimmedMode": true, - "_state": 0, - "_atlas": null, - "_id": "b7hjXlko9MkJzzyeEP7kCo" - }, - { - "__type__": "cc.Button", - "_name": "", - "_objFlags": 0, - "node": { - "__id__": 203 - }, - "_enabled": true, - "duration": 0.1, - "zoomScale": 1.2, - "clickEvents": [ - { - "__id__": 206 - } - ], - "_N$interactable": true, - "_N$enableAutoGrayEffect": false, - "_N$transition": 3, - "transition": 3, - "_N$normalColor": { - "__type__": "cc.Color", - "r": 214, - "g": 214, - "b": 214, - "a": 255 - }, - "_N$pressedColor": { - "__type__": "cc.Color", - "r": 211, - "g": 211, - "b": 211, - "a": 255 - }, - "pressedColor": { - "__type__": "cc.Color", - "r": 211, - "g": 211, - "b": 211, - "a": 255 - }, - "_N$hoverColor": { - "__type__": "cc.Color", - "r": 255, - "g": 255, - "b": 255, - "a": 255 - }, - "hoverColor": { - "__type__": "cc.Color", - "r": 255, - "g": 255, - "b": 255, - "a": 255 - }, - "_N$disabledColor": { - "__type__": "cc.Color", - "r": 124, - "g": 124, - "b": 124, - "a": 255 - }, - "_N$normalSprite": null, - "_N$pressedSprite": null, - "pressedSprite": null, - "_N$hoverSprite": null, - "hoverSprite": null, - "_N$disabledSprite": null, - "_N$target": null, - "_id": "e9CfrIk+hOgYNft+T8gC+X" - }, - { - "__type__": "cc.ClickEvent", - "target": { - "__id__": 190 - }, - "component": "", - "_componentId": "f2e85abZ1NDc58oBSrPm057", - "handler": "onCloseClick", - "customEventData": "" - }, - { - "__type__": "cc.Node", - "_name": "contentNode", - "_objFlags": 0, - "_parent": { - "__id__": 190 - }, - "_children": [], - "_active": true, - "_level": 3, - "_components": [ - { - "__id__": 208 - }, - { - "__id__": 209 - } - ], - "_prefab": null, - "_opacity": 255, - "_color": { - "__type__": "cc.Color", - "r": 255, - "g": 255, - "b": 255, - "a": 255 - }, - "_contentSize": { - "__type__": "cc.Size", - "width": 396, - "height": 280 - }, - "_anchorPoint": { - "__type__": "cc.Vec2", - "x": 0.5, - "y": 0.5 - }, - "_position": { - "__type__": "cc.Vec3", - "x": 0, - "y": 0, - "z": 0 - }, - "_scale": { - "__type__": "cc.Vec3", - "x": 1, - "y": 1, - "z": 1 - }, - "_rotationX": 0, - "_rotationY": 0, - "_quat": { - "__type__": "cc.Quat", - "x": 0, - "y": 0, - "z": 0, - "w": 1 - }, - "_skewX": 0, - "_skewY": 0, - "groupIndex": 0, - "_id": "1cfDUvpZpELJNYna4AkKOt" - }, - { - "__type__": "cc.Sprite", - "_name": "", - "_objFlags": 0, - "node": { - "__id__": 207 - }, - "_enabled": true, - "_srcBlendFactor": 770, - "_dstBlendFactor": 771, - "_spriteFrame": { - "__uuid__": "f201fb81-4964-47e4-a820-bececa838851" - }, - "_type": 1, - "_sizeMode": 0, - "_fillType": 0, - "_fillCenter": { - "__type__": "cc.Vec2", - "x": 0, - "y": 0 - }, - "_fillStart": 0, - "_fillRange": 0, - "_isTrimmedMode": true, - "_state": 0, - "_atlas": null, - "_id": "40JQPz+L5Dra2PfyU7ZHVZ" - }, - { - "__type__": "cc.Layout", - "_name": "", - "_objFlags": 0, - "node": { - "__id__": 207 - }, - "_enabled": true, - "_layoutSize": { - "__type__": "cc.Size", - "width": 300, - "height": 200 - }, - "_resize": 0, - "_N$layoutType": 3, - "_N$padding": 0, - "_N$cellSize": { - "__type__": "cc.Size", - "width": 90, - "height": 120 - }, - "_N$startAxis": 0, - "_N$paddingLeft": 5, - "_N$paddingRight": 5, - "_N$paddingTop": 5, - "_N$paddingBottom": 5, - "_N$spacingX": 5, - "_N$spacingY": 5, - "_N$verticalDirection": 1, - "_N$horizontalDirection": 0, - "_N$affectedByScale": false, - "_id": "f9OPOBE4pGB7ehd2en0apO" - }, - { - "__type__": "cc.Widget", - "_name": "", - "_objFlags": 0, - "node": { - "__id__": 190 - }, - "_enabled": true, - "alignMode": 1, - "_target": null, - "_alignFlags": 45, - "_left": 0, - "_right": 0, - "_top": 0, - "_bottom": 0, - "_verticalCenter": 0, - "_horizontalCenter": 0, - "_isAbsLeft": true, - "_isAbsRight": true, - "_isAbsTop": true, - "_isAbsBottom": true, - "_isAbsHorizontalCenter": true, - "_isAbsVerticalCenter": true, - "_originalWidth": 0, - "_originalHeight": 0, - "_id": "b5wwdmicRHA6C7zUXK+rl7" - }, - { - "__type__": "f2e85abZ1NDc58oBSrPm057", - "_name": "", - "_objFlags": 0, - "node": { - "__id__": 190 - }, - "_enabled": true, - "btnPreb": { - "__uuid__": "edefc8c1-62a6-49f9-8610-13865e5b0e32" - }, - "contentNode": { - "__id__": 207 - }, - "icons": [ - { - "__uuid__": "67fd1c96-89a2-4949-b807-226052342b6c" - }, - { - "__uuid__": "90bf1e2d-12ad-46e5-a4e8-a38ee60dffa4" - }, - { - "__uuid__": "eb181377-d56b-4ee2-b3cc-9ec7367080eb" - }, - { - "__uuid__": "ee2ddc55-f2ed-4cbe-a5cb-0e54b85bf647" - }, - { - "__uuid__": "8917c4b9-d880-44a8-950b-1bea01707e86" - }, - { - "__uuid__": "c2eed000-f86f-4a6b-b25e-338e9e8f012f" - } - ], - "_id": "33Ul50xc5H/aZ5vDbHLgpI" - }, { "__type__": "cc.Widget", "_name": "", @@ -9244,9 +7931,13 @@ "listNode": { "__id__": 143 }, - "menuPanel": { - "__id__": 190 + "menuPreb": { + "__uuid__": "0bfa7bbc-42ab-4204-9fe7-3cd9b56eb045" }, + "qrPreb": { + "__uuid__": "0f14a371-be16-44a1-adcf-319d54c7ba3d" + }, + "menuPanel": null, "_id": "a8YbO7l9lF95gWk3JRycGs" }, { @@ -9275,7 +7966,7 @@ }, "_enabled": true, "webview": { - "__id__": 217 + "__id__": 186 }, "debugText": { "__id__": 6 @@ -9288,7 +7979,7 @@ "_name": "", "_objFlags": 0, "node": { - "__id__": 218 + "__id__": 187 }, "_enabled": true, "_useOriginalSize": false, @@ -9308,7 +7999,7 @@ "_level": 1, "_components": [ { - "__id__": 217 + "__id__": 186 } ], "_prefab": null,