future 1 rok pred
rodič
commit
e25b3c5f9b

+ 8 - 1
assets/data/data.ts

@@ -422,6 +422,7 @@ export class event_item_stop_play_loop_sound{
 export class event_item_delete_drag_other {
     public widget_id:number = -1;
     public delete_drag_other_index:number = -1;
+    public widget_list:event_widget_more_delete_drag_other_event_item[] = [] //列表
 }
 
 export class event_item_play_sound { //播放一个音效
@@ -508,7 +509,13 @@ export class event_item_switch_scene_event extends base_event_item { // 切换
 
 export class event_widget_more_event_item extends base_event_item {
     public binding_widget_id:number = -1; //绑定事件
-    public binding_widget_remark:string = ''; //绑定备注
+    public binding_widget_remark:string = ''; //备注
+}
+
+export class event_widget_more_delete_drag_other_event_item extends base_event_item {
+    public widget_id:number = -1;
+    public widget_remark:string = '';//备注
+    public delete_drag_other_index:number = -1; 
 }
 
 export class UserData {

+ 1 - 1
assets/resources/prefab/edit_event.prefab

@@ -21886,7 +21886,7 @@
     "_spacingY": 30,
     "_verticalDirection": 1,
     "_horizontalDirection": 0,
-    "_constraint": 2,
+    "_constraint": 0,
     "_constraintNum": 3,
     "_affectedByScale": false,
     "_isAlign": false,

+ 308 - 216
assets/resources/prefab/edit_event_more_delete_drag_other_item.prefab

@@ -22,84 +22,33 @@
         "__id__": 2
       },
       {
-        "__id__": 16
-      }
-    ],
-    "_active": true,
-    "_components": [
-      {
-        "__id__": 50
+        "__id__": 8
       },
       {
-        "__id__": 52
+        "__id__": 14
       },
       {
-        "__id__": 54
-      }
-    ],
-    "_prefab": {
-      "__id__": 56
-    },
-    "_lpos": {
-      "__type__": "cc.Vec3",
-      "x": 0,
-      "y": 0,
-      "z": 0
-    },
-    "_lrot": {
-      "__type__": "cc.Quat",
-      "x": 0,
-      "y": 0,
-      "z": 0,
-      "w": 1
-    },
-    "_lscale": {
-      "__type__": "cc.Vec3",
-      "x": 1,
-      "y": 1,
-      "z": 1
-    },
-    "_mobility": 0,
-    "_layer": 33554432,
-    "_euler": {
-      "__type__": "cc.Vec3",
-      "x": 0,
-      "y": 0,
-      "z": 0
-    },
-    "_id": ""
-  },
-  {
-    "__type__": "cc.Node",
-    "_name": "btn_select_widget",
-    "_objFlags": 0,
-    "__editorExtras__": {},
-    "_parent": {
-      "__id__": 1
-    },
-    "_children": [
-      {
-        "__id__": 3
+        "__id__": 48
       }
     ],
     "_active": true,
     "_components": [
       {
-        "__id__": 9
+        "__id__": 54
       },
       {
-        "__id__": 11
+        "__id__": 56
       },
       {
-        "__id__": 13
+        "__id__": 58
       }
     ],
     "_prefab": {
-      "__id__": 15
+      "__id__": 60
     },
     "_lpos": {
       "__type__": "cc.Vec3",
-      "x": -225,
+      "x": 0,
       "y": 0,
       "z": 0
     },
@@ -128,29 +77,29 @@
   },
   {
     "__type__": "cc.Node",
-    "_name": "Label",
+    "_name": "lab_id",
     "_objFlags": 512,
     "__editorExtras__": {},
     "_parent": {
-      "__id__": 2
+      "__id__": 1
     },
     "_children": [],
     "_active": true,
     "_components": [
       {
-        "__id__": 4
+        "__id__": 3
       },
       {
-        "__id__": 6
+        "__id__": 5
       }
     ],
     "_prefab": {
-      "__id__": 8
+      "__id__": 7
     },
     "_lpos": {
       "__type__": "cc.Vec3",
-      "x": 0,
-      "y": 0,
+      "x": -233.976,
+      "y": 25,
       "z": 0
     },
     "_lrot": {
@@ -182,16 +131,16 @@
     "_objFlags": 0,
     "__editorExtras__": {},
     "node": {
-      "__id__": 3
+      "__id__": 2
     },
     "_enabled": true,
     "__prefab": {
-      "__id__": 5
+      "__id__": 4
     },
     "_contentSize": {
       "__type__": "cc.Size",
-      "width": 450,
-      "height": 100
+      "width": 430,
+      "height": 50
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -210,11 +159,11 @@
     "_objFlags": 0,
     "__editorExtras__": {},
     "node": {
-      "__id__": 3
+      "__id__": 2
     },
     "_enabled": true,
     "__prefab": {
-      "__id__": 7
+      "__id__": 6
     },
     "_customMaterial": null,
     "_srcBlendFactor": 2,
@@ -226,7 +175,7 @@
       "b": 0,
       "a": 255
     },
-    "_string": "选择控件",
+    "_string": "id:1000",
     "_horizontalAlign": 1,
     "_verticalAlign": 1,
     "_actualFontSize": 40,
@@ -262,13 +211,63 @@
     "targetOverrides": null,
     "nestedPrefabInstanceRoots": null
   },
+  {
+    "__type__": "cc.Node",
+    "_name": "lab_remark",
+    "_objFlags": 0,
+    "__editorExtras__": {},
+    "_parent": {
+      "__id__": 1
+    },
+    "_children": [],
+    "_active": true,
+    "_components": [
+      {
+        "__id__": 9
+      },
+      {
+        "__id__": 11
+      }
+    ],
+    "_prefab": {
+      "__id__": 13
+    },
+    "_lpos": {
+      "__type__": "cc.Vec3",
+      "x": -235.859,
+      "y": -23.113,
+      "z": 0
+    },
+    "_lrot": {
+      "__type__": "cc.Quat",
+      "x": 0,
+      "y": 0,
+      "z": 0,
+      "w": 1
+    },
+    "_lscale": {
+      "__type__": "cc.Vec3",
+      "x": 1,
+      "y": 1,
+      "z": 1
+    },
+    "_mobility": 0,
+    "_layer": 33554432,
+    "_euler": {
+      "__type__": "cc.Vec3",
+      "x": 0,
+      "y": 0,
+      "z": 0
+    },
+    "_id": ""
+  },
   {
     "__type__": "cc.UITransform",
     "_name": "",
     "_objFlags": 0,
     "__editorExtras__": {},
     "node": {
-      "__id__": 2
+      "__id__": 8
     },
     "_enabled": true,
     "__prefab": {
@@ -276,8 +275,8 @@
     },
     "_contentSize": {
       "__type__": "cc.Size",
-      "width": 450,
-      "height": 100
+      "width": 430,
+      "height": 50.4
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -288,15 +287,15 @@
   },
   {
     "__type__": "cc.CompPrefabInfo",
-    "fileId": "11pg0PMz9PvbvRhoqLOmCB"
+    "fileId": "36qOtHinNNIqA1FjIkg326"
   },
   {
-    "__type__": "cc.Sprite",
+    "__type__": "cc.Label",
     "_name": "",
     "_objFlags": 0,
     "__editorExtras__": {},
     "node": {
-      "__id__": 2
+      "__id__": 8
     },
     "_enabled": true,
     "__prefab": {
@@ -307,88 +306,33 @@
     "_dstBlendFactor": 4,
     "_color": {
       "__type__": "cc.Color",
-      "r": 255,
-      "g": 255,
-      "b": 255,
-      "a": 255
-    },
-    "_spriteFrame": null,
-    "_type": 1,
-    "_fillType": 0,
-    "_sizeMode": 0,
-    "_fillCenter": {
-      "__type__": "cc.Vec2",
-      "x": 0,
-      "y": 0
-    },
-    "_fillStart": 0,
-    "_fillRange": 0,
-    "_isTrimmedMode": true,
-    "_useGrayscale": false,
-    "_atlas": null,
-    "_id": ""
-  },
-  {
-    "__type__": "cc.CompPrefabInfo",
-    "fileId": "afAMEB0ANFn4XDgKLO5mBK"
-  },
-  {
-    "__type__": "cc.Button",
-    "_name": "",
-    "_objFlags": 0,
-    "__editorExtras__": {},
-    "node": {
-      "__id__": 2
-    },
-    "_enabled": true,
-    "__prefab": {
-      "__id__": 14
-    },
-    "clickEvents": [],
-    "_interactable": true,
-    "_transition": 3,
-    "_normalColor": {
-      "__type__": "cc.Color",
-      "r": 214,
-      "g": 214,
-      "b": 214,
-      "a": 255
-    },
-    "_hoverColor": {
-      "__type__": "cc.Color",
-      "r": 211,
-      "g": 211,
-      "b": 211,
-      "a": 255
-    },
-    "_pressedColor": {
-      "__type__": "cc.Color",
-      "r": 255,
-      "g": 255,
-      "b": 255,
-      "a": 255
-    },
-    "_disabledColor": {
-      "__type__": "cc.Color",
-      "r": 124,
-      "g": 124,
-      "b": 124,
+      "r": 0,
+      "g": 0,
+      "b": 0,
       "a": 255
     },
-    "_normalSprite": null,
-    "_hoverSprite": null,
-    "_pressedSprite": null,
-    "_disabledSprite": null,
-    "_duration": 0.1,
-    "_zoomScale": 1.2,
-    "_target": {
-      "__id__": 2
-    },
+    "_string": "",
+    "_horizontalAlign": 1,
+    "_verticalAlign": 1,
+    "_actualFontSize": 31,
+    "_fontSize": 30,
+    "_fontFamily": "Arial",
+    "_lineHeight": 40,
+    "_overflow": 2,
+    "_enableWrapText": true,
+    "_font": null,
+    "_isSystemFontUsed": true,
+    "_spacingX": 0,
+    "_isItalic": false,
+    "_isBold": false,
+    "_isUnderline": false,
+    "_underlineHeight": 2,
+    "_cacheMode": 0,
     "_id": ""
   },
   {
     "__type__": "cc.CompPrefabInfo",
-    "fileId": "f7yWZtscJBe5kfZ/Nj4LmU"
+    "fileId": "adYw5OUd5DeZIjC4uQiw66"
   },
   {
     "__type__": "cc.PrefabInfo",
@@ -398,14 +342,14 @@
     "asset": {
       "__id__": 0
     },
-    "fileId": "c0j0116j5AWKz9qQg6Xd5l",
+    "fileId": "36KEsq+RpGr7tq1Za1lG+5",
     "instance": null,
     "targetOverrides": null,
     "nestedPrefabInstanceRoots": null
   },
   {
     "__type__": "cc.Node",
-    "_name": "dis",
+    "_name": "input",
     "_objFlags": 0,
     "__editorExtras__": {},
     "_parent": {
@@ -413,30 +357,30 @@
     },
     "_children": [
       {
-        "__id__": 17
+        "__id__": 15
       },
       {
-        "__id__": 23
+        "__id__": 21
       }
     ],
     "_active": true,
     "_components": [
       {
-        "__id__": 43
+        "__id__": 41
       },
       {
-        "__id__": 45
+        "__id__": 43
       },
       {
-        "__id__": 47
+        "__id__": 45
       }
     ],
     "_prefab": {
-      "__id__": 49
+      "__id__": 47
     },
     "_lpos": {
       "__type__": "cc.Vec3",
-      "x": 225,
+      "x": 179.666,
       "y": 0,
       "z": 0
     },
@@ -465,24 +409,24 @@
   },
   {
     "__type__": "cc.Node",
-    "_name": "lab_cur_select_dis",
+    "_name": "lab_cur_select",
     "_objFlags": 512,
     "__editorExtras__": {},
     "_parent": {
-      "__id__": 16
+      "__id__": 14
     },
     "_children": [],
     "_active": true,
     "_components": [
       {
-        "__id__": 18
+        "__id__": 16
       },
       {
-        "__id__": 20
+        "__id__": 18
       }
     ],
     "_prefab": {
-      "__id__": 22
+      "__id__": 20
     },
     "_lpos": {
       "__type__": "cc.Vec3",
@@ -519,11 +463,11 @@
     "_objFlags": 0,
     "__editorExtras__": {},
     "node": {
-      "__id__": 17
+      "__id__": 15
     },
     "_enabled": true,
     "__prefab": {
-      "__id__": 19
+      "__id__": 17
     },
     "_contentSize": {
       "__type__": "cc.Size",
@@ -547,11 +491,11 @@
     "_objFlags": 0,
     "__editorExtras__": {},
     "node": {
-      "__id__": 17
+      "__id__": 15
     },
     "_enabled": true,
     "__prefab": {
-      "__id__": 21
+      "__id__": 19
     },
     "_customMaterial": null,
     "_srcBlendFactor": 2,
@@ -601,34 +545,34 @@
   },
   {
     "__type__": "cc.Node",
-    "_name": "btn_select_dis",
+    "_name": "editBox",
     "_objFlags": 0,
     "__editorExtras__": {},
     "_parent": {
-      "__id__": 16
+      "__id__": 14
     },
     "_children": [
       {
-        "__id__": 24
+        "__id__": 22
       },
       {
-        "__id__": 30
+        "__id__": 28
       }
     ],
     "_active": true,
     "_components": [
       {
-        "__id__": 36
+        "__id__": 34
       },
       {
-        "__id__": 38
+        "__id__": 36
       },
       {
-        "__id__": 40
+        "__id__": 38
       }
     ],
     "_prefab": {
-      "__id__": 42
+      "__id__": 40
     },
     "_lpos": {
       "__type__": "cc.Vec3",
@@ -665,20 +609,20 @@
     "_objFlags": 0,
     "__editorExtras__": {},
     "_parent": {
-      "__id__": 23
+      "__id__": 21
     },
     "_children": [],
     "_active": false,
     "_components": [
       {
-        "__id__": 25
+        "__id__": 23
       },
       {
-        "__id__": 27
+        "__id__": 25
       }
     ],
     "_prefab": {
-      "__id__": 29
+      "__id__": 27
     },
     "_lpos": {
       "__type__": "cc.Vec3",
@@ -715,11 +659,11 @@
     "_objFlags": 0,
     "__editorExtras__": {},
     "node": {
-      "__id__": 24
+      "__id__": 22
     },
     "_enabled": true,
     "__prefab": {
-      "__id__": 26
+      "__id__": 24
     },
     "_contentSize": {
       "__type__": "cc.Size",
@@ -743,11 +687,11 @@
     "_objFlags": 0,
     "__editorExtras__": {},
     "node": {
-      "__id__": 24
+      "__id__": 22
     },
     "_enabled": true,
     "__prefab": {
-      "__id__": 28
+      "__id__": 26
     },
     "_customMaterial": null,
     "_srcBlendFactor": 2,
@@ -801,20 +745,20 @@
     "_objFlags": 0,
     "__editorExtras__": {},
     "_parent": {
-      "__id__": 23
+      "__id__": 21
     },
     "_children": [],
     "_active": true,
     "_components": [
       {
-        "__id__": 31
+        "__id__": 29
       },
       {
-        "__id__": 33
+        "__id__": 31
       }
     ],
     "_prefab": {
-      "__id__": 35
+      "__id__": 33
     },
     "_lpos": {
       "__type__": "cc.Vec3",
@@ -851,11 +795,11 @@
     "_objFlags": 0,
     "__editorExtras__": {},
     "node": {
-      "__id__": 30
+      "__id__": 28
     },
     "_enabled": true,
     "__prefab": {
-      "__id__": 32
+      "__id__": 30
     },
     "_contentSize": {
       "__type__": "cc.Size",
@@ -879,11 +823,11 @@
     "_objFlags": 0,
     "__editorExtras__": {},
     "node": {
-      "__id__": 30
+      "__id__": 28
     },
     "_enabled": true,
     "__prefab": {
-      "__id__": 34
+      "__id__": 32
     },
     "_customMaterial": null,
     "_srcBlendFactor": 2,
@@ -937,11 +881,11 @@
     "_objFlags": 0,
     "__editorExtras__": {},
     "node": {
-      "__id__": 23
+      "__id__": 21
     },
     "_enabled": true,
     "__prefab": {
-      "__id__": 37
+      "__id__": 35
     },
     "_contentSize": {
       "__type__": "cc.Size",
@@ -965,11 +909,11 @@
     "_objFlags": 0,
     "__editorExtras__": {},
     "node": {
-      "__id__": 23
+      "__id__": 21
     },
     "_enabled": true,
     "__prefab": {
-      "__id__": 39
+      "__id__": 37
     },
     "_customMaterial": null,
     "_srcBlendFactor": 2,
@@ -1010,21 +954,21 @@
     "_objFlags": 0,
     "__editorExtras__": {},
     "node": {
-      "__id__": 23
+      "__id__": 21
     },
     "_enabled": true,
     "__prefab": {
-      "__id__": 41
+      "__id__": 39
     },
     "editingDidBegan": [],
     "textChanged": [],
     "editingDidEnded": [],
     "editingReturn": [],
     "_textLabel": {
-      "__id__": 27
+      "__id__": 25
     },
     "_placeholderLabel": {
-      "__id__": 33
+      "__id__": 31
     },
     "_returnType": 0,
     "_string": "",
@@ -1061,15 +1005,15 @@
     "_objFlags": 0,
     "__editorExtras__": {},
     "node": {
-      "__id__": 16
+      "__id__": 14
     },
     "_enabled": true,
     "__prefab": {
-      "__id__": 44
+      "__id__": 42
     },
     "_contentSize": {
       "__type__": "cc.Size",
-      "width": 450,
+      "width": 360,
       "height": 100
     },
     "_anchorPoint": {
@@ -1089,11 +1033,11 @@
     "_objFlags": 0,
     "__editorExtras__": {},
     "node": {
-      "__id__": 16
+      "__id__": 14
     },
     "_enabled": true,
     "__prefab": {
-      "__id__": 46
+      "__id__": 44
     },
     "_customMaterial": null,
     "_srcBlendFactor": 2,
@@ -1134,11 +1078,11 @@
     "_objFlags": 0,
     "__editorExtras__": {},
     "node": {
-      "__id__": 16
+      "__id__": 14
     },
     "_enabled": true,
     "__prefab": {
-      "__id__": 48
+      "__id__": 46
     },
     "clickEvents": [],
     "_interactable": true,
@@ -1190,7 +1134,7 @@
     "_duration": 0.1,
     "_zoomScale": 1.2,
     "_target": {
-      "__id__": 16
+      "__id__": 14
     },
     "_id": ""
   },
@@ -1211,6 +1155,142 @@
     "targetOverrides": null,
     "nestedPrefabInstanceRoots": null
   },
+  {
+    "__type__": "cc.Node",
+    "_name": "btn_delete",
+    "_objFlags": 0,
+    "__editorExtras__": {},
+    "_parent": {
+      "__id__": 1
+    },
+    "_children": [],
+    "_active": true,
+    "_components": [
+      {
+        "__id__": 49
+      },
+      {
+        "__id__": 51
+      }
+    ],
+    "_prefab": {
+      "__id__": 53
+    },
+    "_lpos": {
+      "__type__": "cc.Vec3",
+      "x": 405,
+      "y": 0,
+      "z": 0
+    },
+    "_lrot": {
+      "__type__": "cc.Quat",
+      "x": 0,
+      "y": 0,
+      "z": 0,
+      "w": 1
+    },
+    "_lscale": {
+      "__type__": "cc.Vec3",
+      "x": 1,
+      "y": 1,
+      "z": 1
+    },
+    "_mobility": 0,
+    "_layer": 33554432,
+    "_euler": {
+      "__type__": "cc.Vec3",
+      "x": 0,
+      "y": 0,
+      "z": 0
+    },
+    "_id": ""
+  },
+  {
+    "__type__": "cc.UITransform",
+    "_name": "",
+    "_objFlags": 0,
+    "__editorExtras__": {},
+    "node": {
+      "__id__": 48
+    },
+    "_enabled": true,
+    "__prefab": {
+      "__id__": 50
+    },
+    "_contentSize": {
+      "__type__": "cc.Size",
+      "width": 60,
+      "height": 60
+    },
+    "_anchorPoint": {
+      "__type__": "cc.Vec2",
+      "x": 0.5,
+      "y": 0.5
+    },
+    "_id": ""
+  },
+  {
+    "__type__": "cc.CompPrefabInfo",
+    "fileId": "96VtD8qdlI9L0r4rBSFTEW"
+  },
+  {
+    "__type__": "cc.Sprite",
+    "_name": "",
+    "_objFlags": 0,
+    "__editorExtras__": {},
+    "node": {
+      "__id__": 48
+    },
+    "_enabled": true,
+    "__prefab": {
+      "__id__": 52
+    },
+    "_customMaterial": null,
+    "_srcBlendFactor": 2,
+    "_dstBlendFactor": 4,
+    "_color": {
+      "__type__": "cc.Color",
+      "r": 255,
+      "g": 255,
+      "b": 255,
+      "a": 255
+    },
+    "_spriteFrame": {
+      "__uuid__": "64c1f2bf-dc82-4530-bd30-7879d5a3e03e@f9941",
+      "__expectedType__": "cc.SpriteFrame"
+    },
+    "_type": 0,
+    "_fillType": 0,
+    "_sizeMode": 0,
+    "_fillCenter": {
+      "__type__": "cc.Vec2",
+      "x": 0,
+      "y": 0
+    },
+    "_fillStart": 0,
+    "_fillRange": 0,
+    "_isTrimmedMode": true,
+    "_useGrayscale": false,
+    "_atlas": null,
+    "_id": ""
+  },
+  {
+    "__type__": "cc.CompPrefabInfo",
+    "fileId": "e8Oq7J5q5GArLmX/DchAzA"
+  },
+  {
+    "__type__": "cc.PrefabInfo",
+    "root": {
+      "__id__": 1
+    },
+    "asset": {
+      "__id__": 0
+    },
+    "fileId": "17VrwXpANCMp93VN5wM3F0",
+    "instance": null,
+    "targetOverrides": null,
+    "nestedPrefabInstanceRoots": null
+  },
   {
     "__type__": "cc.UITransform",
     "_name": "",
@@ -1221,7 +1301,7 @@
     },
     "_enabled": true,
     "__prefab": {
-      "__id__": 51
+      "__id__": 55
     },
     "_contentSize": {
       "__type__": "cc.Size",
@@ -1249,7 +1329,7 @@
     },
     "_enabled": true,
     "__prefab": {
-      "__id__": 53
+      "__id__": 57
     },
     "_customMaterial": null,
     "_srcBlendFactor": 2,
@@ -1294,7 +1374,19 @@
     },
     "_enabled": true,
     "__prefab": {
-      "__id__": 55
+      "__id__": 59
+    },
+    "lab_id": {
+      "__id__": 2
+    },
+    "lab_remark": {
+      "__id__": 8
+    },
+    "editbox": {
+      "__id__": 38
+    },
+    "btn_delete": {
+      "__id__": 48
     },
     "_id": ""
   },

+ 32 - 5
assets/script/edit/event/edit_event_more_delete_drag_other_item.ts

@@ -1,18 +1,45 @@
-import { _decorator, Component, EditBox, Node } from 'cc';
+import { _decorator, Component, EditBox, Label, Node } from 'cc';
+import { event_widget_more_delete_drag_other_event_item } from '../../../data/data';
+import { tools } from '../../tools';
 const { ccclass, property } = _decorator;
 
 @ccclass('edit_event_more_delete_drag_other_item')
 export class edit_event_more_delete_drag_other_item extends Component {
-    @property(Node) btn_select_widget:Node = null
+    @property(Node) lab_id:Node = null
+    @property(Node) lab_remark:Node = null
     @property(EditBox) editbox:EditBox = null
+    @property(Node) btn_delete:Node = null
+    private m_data:event_widget_more_delete_drag_other_event_item = null
+    private m_delete_callback:Function
     start() {
-        this.btn_select_widget.on(Node.EventType.TOUCH_END, ()=> {
-            
-        })
         this.editbox.node.on(EditBox.EventType.EDITING_DID_ENDED, ()=> {
             let index = parseInt(this.editbox.string)
             console.log('index=',index)
+            this.m_data.delete_drag_other_index = index;
+        })
+        this.btn_delete.on(Node.EventType.TOUCH_END, ()=> {
+            if(this.m_delete_callback!=null) {
+                tools.show_dialog('删除?', ()=>{
+                    this.m_delete_callback()
+                })
+            }
         })
     }
+
+    initView(data:event_widget_more_delete_drag_other_event_item, delete_callback:Function) {
+        this.m_data = data
+        this.m_delete_callback = delete_callback
+        this.lab_id.getComponent(Label).string = 'id:' + data.widget_id
+        if(data.widget_remark.length==0) {
+            this.lab_id.setPosition(this.lab_remark.position.x,0,1)
+        } else {
+            this.lab_id.setPosition(this.lab_remark.position.x,25,1)
+        }
+        this.lab_remark.getComponent(Label).string = data.widget_remark
+        if(data.delete_drag_other_index==-1) {
+        } else {
+            this.editbox.string = data.delete_drag_other_index.toString()
+        }
+    }
 }
 

+ 4 - 1
assets/script/edit/event/edit_event_more_item.ts

@@ -1,5 +1,6 @@
 import { _decorator, Component, Label, Node } from 'cc';
 import { event_widget_more_event_item } from '../../../data/data';
+import { tools } from '../../tools';
 const { ccclass, property } = _decorator;
 
 @ccclass('edit_event_more_item')
@@ -11,7 +12,9 @@ export class edit_event_more_item extends Component {
     start() {
         this.img_delete.on(Node.EventType.TOUCH_END, ()=>{
             if(this.m_delete_callback!=null) {
-                this.m_delete_callback()
+                tools.show_dialog('删除?', ()=>{
+                    this.m_delete_callback()
+                })
             }
         },this)
     }

+ 38 - 2
assets/script/edit/event/event_delete_drag_other_data_view.ts

@@ -1,8 +1,9 @@
-import { _decorator, Component, EditBox, Label, Node, Prefab } from 'cc';
-import { event_item_delete_drag_other, widget_item_data } from '../../../data/data';
+import { _decorator, Component, EditBox, instantiate, Label, Node, Prefab } from 'cc';
+import { event_item_delete_drag_other, event_widget_more_delete_drag_other_event_item, widget_item_data } from '../../../data/data';
 import { Attributes } from '../Attributes';
 import { tools } from '../../tools';
 import { config } from '../../config';
+import { edit_event_more_delete_drag_other_item } from './edit_event_more_delete_drag_other_item';
 const { ccclass, property } = _decorator;
 
 @ccclass('event_delete_drag_other_data_view')
@@ -17,6 +18,11 @@ export class event_delete_drag_other_data_view extends Component {
     // @property(Node) lab_cur_select_other:Node = null;
     private m_data:event_item_delete_drag_other = null;
     private m_widget_item_data:widget_item_data = null;
+    protected start(): void {
+        this.btn_more.on(Node.EventType.TOUCH_END, ()=> {
+            this.onClickMoreBtn()
+        })
+    }
     public initView(data:event_item_delete_drag_other){
         this.m_data = data;
         this.btn_select_widget.on(Node.EventType.TOUCH_END,()=>{
@@ -52,6 +58,7 @@ export class event_delete_drag_other_data_view extends Component {
             this.updateStatus()
         })
         this.updateStatus()
+        this.updateMoreListStatus()
     }
     updateStatus(){
         if(this.m_data.widget_id==-1){
@@ -70,6 +77,35 @@ export class event_delete_drag_other_data_view extends Component {
         }
 
     }
+    onClickMoreBtn() {
+        let list =  Attributes.Singleton.get_cur_scene_widget_by_type(config.Widget_Type_List.DRAG_TYPE)
+        if(list.length<=0){
+            return tools.showToast("当前场景没有添加拖拽控件!")
+        }
+        tools.show_select_widget_list(list,(item:widget_item_data)=>{
+            let more_item = new event_widget_more_delete_drag_other_event_item
+            more_item.widget_id = item.att.id
+            more_item.widget_remark = item.att.remark
+            more_item.delete_drag_other_index = -1
+            this.m_data.widget_list.push(more_item)
+            this.updateMoreListStatus()
+        })
+    }
+    updateMoreListStatus() {
+        if(this.m_data.widget_list==undefined) {
+            this.m_data.widget_list = []
+        }
+        this.content.removeAllChildren()
+        for(let index = 0; index < this.m_data.widget_list.length; index ++) {
+            const element = this.m_data.widget_list[index]
+            let item = instantiate(this.item_more_delete_drag_other_prefab);
+            item.parent = this.content;
+            item.getComponent(edit_event_more_delete_drag_other_item).initView(element, ()=>{
+                this.m_data.widget_list.splice(index,1)
+                this.updateMoreListStatus()
+            })
+        }
+    }
 }