ソースを参照

Merge branch 'master' of http://120.92.132.192:23541/TDGame/TDGameClient3D

greg 4 年 前
コミット
1eeeca575b

+ 5 - 4
assets/resources/ui/GameOverUI.prefab

@@ -315,7 +315,7 @@
         "__id__": 56
       }
     ],
-    "_active": false,
+    "_active": true,
     "_components": [
       {
         "__id__": 67
@@ -1809,7 +1809,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": 0,
-      "y": -456.004,
+      "y": -523.317,
       "z": 0
     },
     "_lrot": {
@@ -2201,7 +2201,7 @@
         "__id__": 102
       }
     ],
-    "_active": true,
+    "_active": false,
     "_components": [
       {
         "__id__": 113
@@ -3235,7 +3235,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": 0,
-      "y": -381.031,
+      "y": -479.897,
       "z": 0
     },
     "_lrot": {
@@ -7501,6 +7501,7 @@
     "scrollType": 2,
     "autoScroll": true,
     "scrollSpeed": 50,
+    "isShowFull": false,
     "_id": ""
   },
   {

+ 16 - 0
assets/scripts/engines/gui/GUIManager.ts

@@ -72,6 +72,22 @@ export class GUIManager{
         }
     }
 
+    /**
+     * 界面是否在显示
+     */
+    isShowing(key:number):boolean{
+        if(this.m_guiMap.has(key)==false){
+            throw new Error("未注册的UI:"+key);
+        }
+
+        if(this.m_showing.has(key)){
+            return true
+        }else{
+            return false
+        }
+
+    }
+
     /**
      * 单例
      */

+ 6 - 2
assets/scripts/engines/gui/list/ExportItem.ts

@@ -20,13 +20,15 @@ export class ExportItem extends Component {
     label:LabelComponent=null;
     
     data:any;
+    isShowFull:boolean;
 
     start () {
         this.node.on(Node.EventType.TOUCH_START,this.__itemTouchStart.bind(this),this);
     }
 
-    updateItem(data:any):void{
+    updateItem(data:any, isShowFull:boolean=true):void{
         this.data=data;
+        this.isShowFull = isShowFull;
         this.label.string=this.data.name;
         loader.load(this.data.icon,this.__loadProgress.bind(this),this.__loadComplete.bind(this));
     }
@@ -47,7 +49,9 @@ export class ExportItem extends Component {
                     LiangLiangSDK.CpaReport(self.data);
                 },
                 fail: (res) => {
-                    GUIManager.single.Show(UIConst.FULL_OUTPUT_UI);
+                    if(this.isShowFull){
+                        GUIManager.single.Show(UIConst.FULL_OUTPUT_UI);
+                    }
                     console.log("跳转失败!");
                 },
                 complete: (res) => {},

+ 7 - 1
assets/scripts/engines/gui/list/ExportList.ts

@@ -47,6 +47,12 @@ export class ExportList extends Component {
     })
     scrollSpeed: number = 50;
 
+    @property({
+        type: CCBoolean,
+        tooltip: "取消是否到全屏导出"
+    })
+    isShowFull:boolean = true;
+
     //前进还是后退
     isAdvance: boolean = true;
 
@@ -79,7 +85,7 @@ export class ExportList extends Component {
             item = itemNode.getComponent(ExportItem);
             this.__items.push(item);
             this.content.addChild(itemNode);
-            item.updateItem(data);
+            item.updateItem(data, this.isShowFull);
         }
         this.scrollView.scheduleOnce(this.__scroll.bind(this), 0.5);
     }