NewBattleChat_Generate.lua 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525
  1. ---@class NewBattleChat__Generate_btnBlock_text
  2. ---@field public gameObject UnityEngine.GameObject
  3. ---@field public text TMPro.TextMeshProUGUI
  4. ---@class NewBattleChat__Generate_btnBlock
  5. ---@field public gameObject UnityEngine.GameObject
  6. ---@field public button UnityEngine.UI.Button
  7. ---@field public text NewBattleChat__Generate_btnBlock_text
  8. ---@class NewBattleChat__Generate_btnAddFriend_text
  9. ---@field public gameObject UnityEngine.GameObject
  10. ---@field public text TMPro.TextMeshProUGUI
  11. ---@class NewBattleChat__Generate_btnAddFriend
  12. ---@field public gameObject UnityEngine.GameObject
  13. ---@field public button UnityEngine.UI.Button
  14. ---@field public text NewBattleChat__Generate_btnAddFriend_text
  15. ---@class NewBattleChat__Generate_btnInfor
  16. ---@field public gameObject UnityEngine.GameObject
  17. ---@field public button UnityEngine.UI.Button
  18. ---@class NewBattleChat__Generate_btnPrivateChat
  19. ---@field public gameObject UnityEngine.GameObject
  20. ---@field public button UnityEngine.UI.Button
  21. ---@class NewBattleChat__Generate_headOrder
  22. ---@field public gameObject UnityEngine.GameObject
  23. ---@field public rectTransform UnityEngine.RectTransform
  24. ---@class NewBattleChat__Generate_funcbg
  25. ---@field public gameObject UnityEngine.GameObject
  26. ---@field public button UnityEngine.UI.Button
  27. ---@class NewBattleChat__Generate_battleLogView_content
  28. ---@field public gameObject UnityEngine.GameObject
  29. ---@field public verticalLayoutGroup UnityEngine.UI.VerticalLayoutGroup
  30. ---@class NewBattleChat__Generate_battleLogView
  31. ---@field public gameObject UnityEngine.GameObject
  32. ---@field public loopVerticalScrollRect UnityEngine.UI.LoopVerticalScrollRect
  33. ---@field public uIEventTriggerListener UIEventTriggerListener
  34. ---@field public content NewBattleChat__Generate_battleLogView_content
  35. ---@class NewBattleChat__Generate_battleLogRoot
  36. ---@field public gameObject UnityEngine.GameObject
  37. ---@field public uIEventTriggerListener UIEventTriggerListener
  38. ---@class NewBattleChat__Generate_togwarlog
  39. ---@field public gameObject UnityEngine.GameObject
  40. ---@field public toggle UnityEngine.UI.Toggle
  41. ---@class NewBattleChat__Generate_togsystem
  42. ---@field public gameObject UnityEngine.GameObject
  43. ---@field public toggle UnityEngine.UI.Toggle
  44. ---@class NewBattleChat__Generate_togguild
  45. ---@field public gameObject UnityEngine.GameObject
  46. ---@field public toggle UnityEngine.UI.Toggle
  47. ---@class NewBattleChat__Generate_togworld
  48. ---@field public gameObject UnityEngine.GameObject
  49. ---@field public toggle UnityEngine.UI.Toggle
  50. ---@class NewBattleChat__Generate_btnChat
  51. ---@field public gameObject UnityEngine.GameObject
  52. ---@field public button UnityEngine.UI.Button
  53. ---@class NewBattleChat__Generate_chltogBg
  54. ---@field public gameObject UnityEngine.GameObject
  55. ---@field public toggleGroup UnityEngine.UI.ToggleGroup
  56. ---@field public canvasGroup UnityEngine.CanvasGroup
  57. ---@class NewBattleChat__Generate_chatTextItem
  58. ---@field public gameObject UnityEngine.GameObject
  59. ---@field public rectTransform UnityEngine.RectTransform
  60. ---@field public layoutElement UnityEngine.UI.LayoutElement
  61. ---@class NewBattleChat__Generate_chatView
  62. ---@field public gameObject UnityEngine.GameObject
  63. ---@field public uIEventTriggerListener UIEventTriggerListener
  64. ---@field public loopListView SuperScrollView.LoopListView
  65. ---@class NewBattleChat__Generate
  66. ---@field private gameObject UnityEngine.GameObject
  67. ---@field private transform UnityEngine.Transform
  68. ---@field private chatRoot UnityEngine.GameObject
  69. ---@field private chatView NewBattleChat__Generate_chatView
  70. ---@field private chatTextItem NewBattleChat__Generate_chatTextItem
  71. ---@field private chltogBg NewBattleChat__Generate_chltogBg
  72. ---@field private btnChat NewBattleChat__Generate_btnChat
  73. ---@field private togworld NewBattleChat__Generate_togworld
  74. ---@field private togguild NewBattleChat__Generate_togguild
  75. ---@field private togsystem NewBattleChat__Generate_togsystem
  76. ---@field private togwarlog NewBattleChat__Generate_togwarlog
  77. ---@field private battleLogRoot NewBattleChat__Generate_battleLogRoot
  78. ---@field private battleLogView NewBattleChat__Generate_battleLogView
  79. ---@field private funcbg NewBattleChat__Generate_funcbg
  80. ---@field private headOrder NewBattleChat__Generate_headOrder
  81. ---@field private btnPrivateChat NewBattleChat__Generate_btnPrivateChat
  82. ---@field private btnInfor NewBattleChat__Generate_btnInfor
  83. ---@field private btnAddFriend NewBattleChat__Generate_btnAddFriend
  84. ---@field private btnBlock NewBattleChat__Generate_btnBlock
  85. local NewBattleChatView = class("NewBattleChatView")
  86. function NewBattleChatView:ctor()
  87. end
  88. ---@private
  89. function NewBattleChatView:SetActive(result)
  90. self.gameObject:SetActive(result)
  91. end
  92. ---@private
  93. function NewBattleChatView:InitGenerate(Root, data)
  94. self.transform = Root
  95. self.inited = true
  96. local tmp
  97. self:InitGenerate__1(Root,data)
  98. self:InitGenerate__2(Root,data)
  99. self:InitGenerate__3(Root,data)
  100. self:InitGenerate__4(Root,data)
  101. self:InitGenerate__5(Root,data)
  102. self:InitGenerate__6(Root,data)
  103. self:InitGenerate__7(Root,data)
  104. self:InitGenerate__8(Root,data)
  105. self:InitGenerate__9(Root,data)
  106. self:InitGenerate__10(Root,data)
  107. self:InitGenerate__11(Root,data)
  108. self:InitGenerate__12(Root,data)
  109. self:InitGenerate__13(Root,data)
  110. self:InitGenerate__14(Root,data)
  111. self:InitGenerate__15(Root,data)
  112. self:InitGenerate__16(Root,data)
  113. self:InitGenerate__17(Root,data)
  114. self:InitGenerate__18(Root,data)
  115. self:InitGenerate__19(Root,data)
  116. self:InitGenerate__20(Root,data)
  117. self:InitGenerate__21(Root,data)
  118. end
  119. ---@private
  120. function NewBattleChatView:InitGenerate__1(Root, data)
  121. --[[
  122. Root
  123. --]]
  124. end
  125. ---@private
  126. function NewBattleChatView:InitGenerate__2(Root, data)
  127. --[[
  128. ChatRoot
  129. --]]
  130. local tmp = Root:Find("ChatRoot").gameObject
  131. if tolua.getpeer(tmp) == nil then
  132. tolua.setpeer(tmp, {})
  133. end
  134. self.chatRoot = tmp
  135. end
  136. ---@private
  137. function NewBattleChatView:InitGenerate__3(Root, data)
  138. --[[
  139. ChatRoot/ChatView
  140. --]]
  141. local tmp = Root:Find("ChatRoot/ChatView").gameObject
  142. if tolua.getpeer(tmp) == nil then
  143. tolua.setpeer(tmp, {})
  144. end
  145. self.chatView = tmp
  146. tmp.uIEventTriggerListener = tmp:GetComponent(Enum.TypeInfo.UIEventTriggerListener)
  147. tmp.loopListView = tmp:GetComponent(Enum.TypeInfo.LoopListView)
  148. end
  149. ---@private
  150. function NewBattleChatView:InitGenerate__4(Root, data)
  151. --[[
  152. ChatRoot/ChatView/Viewport/Content/ChatTextItem
  153. --]]
  154. local tmp = Root:Find("ChatRoot/ChatView/Viewport/Content/ChatTextItem").gameObject
  155. if tolua.getpeer(tmp) == nil then
  156. tolua.setpeer(tmp, {})
  157. end
  158. self.chatTextItem = CommonUtil.BindGridViewItem2LuaStatic("ChatTextItem", tmp)
  159. self.chatTextItem.prefabName = "ChatTextItem"
  160. tmp.rectTransform = tmp:GetComponent(Enum.TypeInfo.RectTransform)
  161. tmp.layoutElement = tmp:GetComponent(Enum.TypeInfo.LayoutElement)
  162. end
  163. ---@private
  164. function NewBattleChatView:InitGenerate__5(Root, data)
  165. --[[
  166. ChatRoot/ChltogBg
  167. --]]
  168. local tmp = Root:Find("ChatRoot/ChltogBg").gameObject
  169. if tolua.getpeer(tmp) == nil then
  170. tolua.setpeer(tmp, {})
  171. end
  172. self.chltogBg = tmp
  173. tmp.toggleGroup = tmp:GetComponent(Enum.TypeInfo.ToggleGroup)
  174. tmp.canvasGroup = tmp:GetComponent(Enum.TypeInfo.CanvasGroup)
  175. end
  176. ---@private
  177. function NewBattleChatView:InitGenerate__6(Root, data)
  178. --[[
  179. ChatRoot/ChltogBg/GameObject/BtnChat
  180. --]]
  181. local tmp = Root:Find("ChatRoot/ChltogBg/GameObject/BtnChat").gameObject
  182. if tolua.getpeer(tmp) == nil then
  183. tolua.setpeer(tmp, {})
  184. end
  185. self.btnChat = tmp
  186. tmp.button = tmp:GetComponent(Enum.TypeInfo.Button)
  187. end
  188. ---@private
  189. function NewBattleChatView:InitGenerate__7(Root, data)
  190. --[[
  191. ChatRoot/ChltogBg/Togworld
  192. --]]
  193. local tmp = Root:Find("ChatRoot/ChltogBg/Togworld").gameObject
  194. if tolua.getpeer(tmp) == nil then
  195. tolua.setpeer(tmp, {})
  196. end
  197. self.togworld = tmp
  198. tmp.toggle = tmp:GetComponent(Enum.TypeInfo.Toggle)
  199. end
  200. ---@private
  201. function NewBattleChatView:InitGenerate__8(Root, data)
  202. --[[
  203. ChatRoot/ChltogBg/Togguild
  204. --]]
  205. local tmp = Root:Find("ChatRoot/ChltogBg/Togguild").gameObject
  206. if tolua.getpeer(tmp) == nil then
  207. tolua.setpeer(tmp, {})
  208. end
  209. self.togguild = tmp
  210. tmp.toggle = tmp:GetComponent(Enum.TypeInfo.Toggle)
  211. end
  212. ---@private
  213. function NewBattleChatView:InitGenerate__9(Root, data)
  214. --[[
  215. ChatRoot/ChltogBg/Togsystem
  216. --]]
  217. local tmp = Root:Find("ChatRoot/ChltogBg/Togsystem").gameObject
  218. if tolua.getpeer(tmp) == nil then
  219. tolua.setpeer(tmp, {})
  220. end
  221. self.togsystem = tmp
  222. tmp.toggle = tmp:GetComponent(Enum.TypeInfo.Toggle)
  223. end
  224. ---@private
  225. function NewBattleChatView:InitGenerate__10(Root, data)
  226. --[[
  227. ChatRoot/ChltogBg/Togwarlog
  228. --]]
  229. local tmp = Root:Find("ChatRoot/ChltogBg/Togwarlog").gameObject
  230. if tolua.getpeer(tmp) == nil then
  231. tolua.setpeer(tmp, {})
  232. end
  233. self.togwarlog = tmp
  234. tmp.toggle = tmp:GetComponent(Enum.TypeInfo.Toggle)
  235. end
  236. ---@private
  237. function NewBattleChatView:InitGenerate__11(Root, data)
  238. --[[
  239. ChatRoot/BattleLogRoot
  240. --]]
  241. local tmp = Root:Find("ChatRoot/BattleLogRoot").gameObject
  242. if tolua.getpeer(tmp) == nil then
  243. tolua.setpeer(tmp, {})
  244. end
  245. self.battleLogRoot = tmp
  246. tmp.uIEventTriggerListener = tmp:GetComponent(Enum.TypeInfo.UIEventTriggerListener)
  247. end
  248. ---@private
  249. function NewBattleChatView:InitGenerate__12(Root, data)
  250. --[[
  251. ChatRoot/BattleLogRoot/BattleLogView
  252. --]]
  253. local tmp = Root:Find("ChatRoot/BattleLogRoot/BattleLogView").gameObject
  254. if tolua.getpeer(tmp) == nil then
  255. tolua.setpeer(tmp, {})
  256. end
  257. self.battleLogView = tmp
  258. tmp.loopVerticalScrollRect = tmp:GetComponent(Enum.TypeInfo.LoopVerticalScrollRect)
  259. tmp.uIEventTriggerListener = tmp:GetComponent(Enum.TypeInfo.UIEventTriggerListener)
  260. end
  261. ---@private
  262. function NewBattleChatView:InitGenerate__13(Root, data)
  263. --[[
  264. ChatRoot/BattleLogRoot/BattleLogView/Viewport/Content
  265. --]]
  266. local tmp = Root:Find("ChatRoot/BattleLogRoot/BattleLogView/Viewport/Content").gameObject
  267. if tolua.getpeer(tmp) == nil then
  268. tolua.setpeer(tmp, {})
  269. end
  270. self.battleLogView.content = tmp
  271. tmp.verticalLayoutGroup = tmp:GetComponent(Enum.TypeInfo.VerticalLayoutGroup)
  272. end
  273. ---@private
  274. function NewBattleChatView:InitGenerate__14(Root, data)
  275. --[[
  276. funcbg
  277. --]]
  278. local tmp = Root:Find("funcbg").gameObject
  279. if tolua.getpeer(tmp) == nil then
  280. tolua.setpeer(tmp, {})
  281. end
  282. self.funcbg = tmp
  283. tmp.button = tmp:GetComponent(Enum.TypeInfo.Button)
  284. end
  285. ---@private
  286. function NewBattleChatView:InitGenerate__15(Root, data)
  287. --[[
  288. funcbg/HeadOrder
  289. --]]
  290. local tmp = Root:Find("funcbg/HeadOrder").gameObject
  291. if tolua.getpeer(tmp) == nil then
  292. tolua.setpeer(tmp, {})
  293. end
  294. self.headOrder = tmp
  295. tmp.rectTransform = tmp:GetComponent(Enum.TypeInfo.RectTransform)
  296. end
  297. ---@private
  298. function NewBattleChatView:InitGenerate__16(Root, data)
  299. --[[
  300. funcbg/HeadOrder/BtnPrivateChat
  301. --]]
  302. local tmp = Root:Find("funcbg/HeadOrder/BtnPrivateChat").gameObject
  303. if tolua.getpeer(tmp) == nil then
  304. tolua.setpeer(tmp, {})
  305. end
  306. self.btnPrivateChat = tmp
  307. tmp.button = tmp:GetComponent(Enum.TypeInfo.Button)
  308. end
  309. ---@private
  310. function NewBattleChatView:InitGenerate__17(Root, data)
  311. --[[
  312. funcbg/HeadOrder/BtnInfor
  313. --]]
  314. local tmp = Root:Find("funcbg/HeadOrder/BtnInfor").gameObject
  315. if tolua.getpeer(tmp) == nil then
  316. tolua.setpeer(tmp, {})
  317. end
  318. self.btnInfor = tmp
  319. tmp.button = tmp:GetComponent(Enum.TypeInfo.Button)
  320. end
  321. ---@private
  322. function NewBattleChatView:InitGenerate__18(Root, data)
  323. --[[
  324. funcbg/HeadOrder/BtnAddFriend
  325. --]]
  326. local tmp = Root:Find("funcbg/HeadOrder/BtnAddFriend").gameObject
  327. if tolua.getpeer(tmp) == nil then
  328. tolua.setpeer(tmp, {})
  329. end
  330. self.btnAddFriend = tmp
  331. tmp.button = tmp:GetComponent(Enum.TypeInfo.Button)
  332. end
  333. ---@private
  334. function NewBattleChatView:InitGenerate__19(Root, data)
  335. --[[
  336. funcbg/HeadOrder/BtnAddFriend/Text
  337. --]]
  338. local tmp = Root:Find("funcbg/HeadOrder/BtnAddFriend/Text").gameObject
  339. if tolua.getpeer(tmp) == nil then
  340. tolua.setpeer(tmp, {})
  341. end
  342. self.btnAddFriend.text = tmp
  343. tmp.text = tmp:GetComponent(Enum.TypeInfo.TextMeshProUGUI)
  344. end
  345. ---@private
  346. function NewBattleChatView:InitGenerate__20(Root, data)
  347. --[[
  348. funcbg/HeadOrder/BtnBlock
  349. --]]
  350. local tmp = Root:Find("funcbg/HeadOrder/BtnBlock").gameObject
  351. if tolua.getpeer(tmp) == nil then
  352. tolua.setpeer(tmp, {})
  353. end
  354. self.btnBlock = tmp
  355. tmp.button = tmp:GetComponent(Enum.TypeInfo.Button)
  356. end
  357. ---@private
  358. function NewBattleChatView:InitGenerate__21(Root, data)
  359. --[[
  360. funcbg/HeadOrder/BtnBlock/Text
  361. --]]
  362. local tmp = Root:Find("funcbg/HeadOrder/BtnBlock/Text").gameObject
  363. if tolua.getpeer(tmp) == nil then
  364. tolua.setpeer(tmp, {})
  365. end
  366. self.btnBlock.text = tmp
  367. tmp.text = tmp:GetComponent(Enum.TypeInfo.TextMeshProUGUI)
  368. end
  369. ---@private
  370. function NewBattleChatView:GenerateDestroy()
  371. if tolua.getpeer(self.btnBlock.text) ~= nil then
  372. tolua.setpeer(self.btnBlock.text, nil)
  373. end
  374. if tolua.getpeer(self.btnAddFriend.text) ~= nil then
  375. tolua.setpeer(self.btnAddFriend.text, nil)
  376. end
  377. if tolua.getpeer(self.battleLogView.content) ~= nil then
  378. tolua.setpeer(self.battleLogView.content, nil)
  379. end
  380. if tolua.getpeer(self.chatRoot) ~= nil then
  381. tolua.setpeer(self.chatRoot, nil)
  382. end
  383. self.chatRoot = nil
  384. if tolua.getpeer(self.chatView) ~= nil then
  385. tolua.setpeer(self.chatView, nil)
  386. end
  387. self.chatView = nil
  388. if self.chatTextItem.GenerateDestroy ~= nil then
  389. self.chatTextItem:GenerateDestroy()
  390. end
  391. if tolua.getpeer(self.chatTextItem) ~= nil then
  392. tolua.setpeer(self.chatTextItem, nil)
  393. end
  394. self.chatTextItem = nil
  395. if tolua.getpeer(self.chltogBg) ~= nil then
  396. tolua.setpeer(self.chltogBg, nil)
  397. end
  398. self.chltogBg = nil
  399. if tolua.getpeer(self.btnChat) ~= nil then
  400. tolua.setpeer(self.btnChat, nil)
  401. end
  402. self.btnChat = nil
  403. if tolua.getpeer(self.togworld) ~= nil then
  404. tolua.setpeer(self.togworld, nil)
  405. end
  406. self.togworld = nil
  407. if tolua.getpeer(self.togguild) ~= nil then
  408. tolua.setpeer(self.togguild, nil)
  409. end
  410. self.togguild = nil
  411. if tolua.getpeer(self.togsystem) ~= nil then
  412. tolua.setpeer(self.togsystem, nil)
  413. end
  414. self.togsystem = nil
  415. if tolua.getpeer(self.togwarlog) ~= nil then
  416. tolua.setpeer(self.togwarlog, nil)
  417. end
  418. self.togwarlog = nil
  419. if tolua.getpeer(self.battleLogRoot) ~= nil then
  420. tolua.setpeer(self.battleLogRoot, nil)
  421. end
  422. self.battleLogRoot = nil
  423. if tolua.getpeer(self.battleLogView) ~= nil then
  424. tolua.setpeer(self.battleLogView, nil)
  425. end
  426. self.battleLogView = nil
  427. if tolua.getpeer(self.funcbg) ~= nil then
  428. tolua.setpeer(self.funcbg, nil)
  429. end
  430. self.funcbg = nil
  431. if tolua.getpeer(self.headOrder) ~= nil then
  432. tolua.setpeer(self.headOrder, nil)
  433. end
  434. self.headOrder = nil
  435. if tolua.getpeer(self.btnPrivateChat) ~= nil then
  436. tolua.setpeer(self.btnPrivateChat, nil)
  437. end
  438. self.btnPrivateChat = nil
  439. if tolua.getpeer(self.btnInfor) ~= nil then
  440. tolua.setpeer(self.btnInfor, nil)
  441. end
  442. self.btnInfor = nil
  443. if tolua.getpeer(self.btnAddFriend) ~= nil then
  444. tolua.setpeer(self.btnAddFriend, nil)
  445. end
  446. self.btnAddFriend = nil
  447. if tolua.getpeer(self.btnBlock) ~= nil then
  448. tolua.setpeer(self.btnBlock, nil)
  449. end
  450. self.btnBlock = nil
  451. self.transform = nil
  452. self.gameObject = nil
  453. self.inited = false
  454. end
  455. return NewBattleChatView