UIREShopView_Generate.lua 8.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289
  1. ---@class UIREShop__Generate_redEnvelope_btnSure
  2. ---@field public gameObject UnityEngine.GameObject
  3. ---@field public button UnityEngine.UI.Button
  4. ---@class UIREShop__Generate_redEnvelope_desc
  5. ---@field public gameObject UnityEngine.GameObject
  6. ---@field public text UnityEngine.UI.Text
  7. ---@class UIREShop__Generate_redEnvelope
  8. ---@field public gameObject UnityEngine.GameObject
  9. ---@field public desc UIREShop__Generate_redEnvelope_desc
  10. ---@field public btnSure UIREShop__Generate_redEnvelope_btnSure
  11. ---@class UIREShop__Generate_btnInfo
  12. ---@field public gameObject UnityEngine.GameObject
  13. ---@field public button UnityEngine.UI.Button
  14. ---@class UIREShop__Generate_btnClose
  15. ---@field public gameObject UnityEngine.GameObject
  16. ---@field public button UnityEngine.UI.Button
  17. ---@class UIREShop__Generate_runeShopGoodsItem
  18. ---@field public gameObject UnityEngine.GameObject
  19. ---@field public button UnityEngine.UI.Button
  20. ---@class UIREShop__Generate_goodsScrollView
  21. ---@field public gameObject UnityEngine.GameObject
  22. ---@field public loopGridView SuperScrollView.LoopGridView
  23. ---@class UIREShop__Generate_AnyBtn
  24. ---@field public gameObject UnityEngine.GameObject
  25. ---@field public button UnityEngine.UI.Button
  26. ---@class UIREShop__Generate_uIAnimator
  27. ---@field public gameObject UnityEngine.GameObject
  28. ---@field public animator UnityEngine.Animator
  29. ---@class UIREShop__Generate
  30. ---@field private gameObject UnityEngine.GameObject
  31. ---@field private transform UnityEngine.Transform
  32. ---@field private uIAnimator UIREShop__Generate_uIAnimator
  33. ---@field private AnyBtn UIREShop__Generate_AnyBtn
  34. ---@field private goodsScrollView UIREShop__Generate_goodsScrollView
  35. ---@field private runeShopGoodsItem UIREShop__Generate_runeShopGoodsItem
  36. ---@field private btnClose UIREShop__Generate_btnClose
  37. ---@field private btnInfo UIREShop__Generate_btnInfo
  38. ---@field private resourceBox UnityEngine.GameObject
  39. ---@field private shopCurrencyItem UnityEngine.GameObject
  40. ---@field private redEnvelope UIREShop__Generate_redEnvelope
  41. local UIREShopView = class("UIREShopView", require("UIViewBase"))
  42. function UIREShopView:ctor()
  43. end
  44. ---@private
  45. function UIREShopView:SetActive(result)
  46. self.gameObject:SetActive(result)
  47. end
  48. ---@private
  49. function UIREShopView:InitGenerate(Root, data)
  50. self.transform = Root
  51. self.inited = true
  52. if self.super.Init then
  53. self.super.Init(self)
  54. end
  55. local tmp
  56. self:InitGenerate__1(Root,data)
  57. self:InitGenerate__2(Root,data)
  58. self:InitGenerate__3(Root,data)
  59. self:InitGenerate__4(Root,data)
  60. self:InitGenerate__5(Root,data)
  61. self:InitGenerate__6(Root,data)
  62. self:InitGenerate__7(Root,data)
  63. self:InitGenerate__8(Root,data)
  64. self:InitGenerate__9(Root,data)
  65. self:InitGenerate__10(Root,data)
  66. self:InitGenerate__11(Root,data)
  67. end
  68. ---@private
  69. function UIREShopView:InitGenerate__1(Root, data)
  70. --[[
  71. UIAnimator
  72. --]]
  73. local tmp = Root:Find("UIAnimator").gameObject
  74. if tolua.getpeer(tmp) == nil then
  75. tolua.setpeer(tmp, {})
  76. end
  77. self.uIAnimator = tmp
  78. tmp.animator = tmp:GetComponent(Enum.TypeInfo.Animator)
  79. tmp.animator.logWarnings = false
  80. end
  81. ---@private
  82. function UIREShopView:InitGenerate__2(Root, data)
  83. --[[
  84. UIAnimator/Alpha
  85. --]]
  86. local tmp = Root:Find("UIAnimator/Alpha").gameObject
  87. if tolua.getpeer(tmp) == nil then
  88. tolua.setpeer(tmp, {})
  89. end
  90. self.AnyBtn = tmp
  91. tmp.button = tmp:GetComponent(Enum.TypeInfo.Button)
  92. end
  93. ---@private
  94. function UIREShopView:InitGenerate__3(Root, data)
  95. --[[
  96. UIAnimator/Window/GoodsBox/GoodsScrollView
  97. --]]
  98. local tmp = Root:Find("UIAnimator/Window/GoodsBox/GoodsScrollView").gameObject
  99. if tolua.getpeer(tmp) == nil then
  100. tolua.setpeer(tmp, {})
  101. end
  102. self.goodsScrollView = tmp
  103. tmp.loopGridView = tmp:GetComponent(Enum.TypeInfo.LoopGridView)
  104. end
  105. ---@private
  106. function UIREShopView:InitGenerate__4(Root, data)
  107. --[[
  108. UIAnimator/Window/GoodsBox/GoodsScrollView/Viewport/Content/RuneShopGoodsItem
  109. --]]
  110. local tmp = Root:Find("UIAnimator/Window/GoodsBox/GoodsScrollView/Viewport/Content/RuneShopGoodsItem").gameObject
  111. if tolua.getpeer(tmp) == nil then
  112. tolua.setpeer(tmp, {})
  113. end
  114. self.runeShopGoodsItem = CommonUtil.BindGridViewItem2LuaStatic("RuneShopGoodsItem", tmp)
  115. self.runeShopGoodsItem.prefabName = "RuneShopGoodsItem"
  116. tmp.button = tmp:GetComponent(Enum.TypeInfo.Button)
  117. end
  118. ---@private
  119. function UIREShopView:InitGenerate__5(Root, data)
  120. --[[
  121. UIAnimator/Window/BottomAnim/BtnClose
  122. --]]
  123. local tmp = Root:Find("UIAnimator/Window/BottomAnim/BtnClose").gameObject
  124. if tolua.getpeer(tmp) == nil then
  125. tolua.setpeer(tmp, {})
  126. end
  127. self.btnClose = tmp
  128. tmp.button = tmp:GetComponent(Enum.TypeInfo.Button)
  129. end
  130. ---@private
  131. function UIREShopView:InitGenerate__6(Root, data)
  132. --[[
  133. UIAnimator/Window/TopView/BtnInfo
  134. --]]
  135. local tmp = Root:Find("UIAnimator/Window/TopView/BtnInfo").gameObject
  136. if tolua.getpeer(tmp) == nil then
  137. tolua.setpeer(tmp, {})
  138. end
  139. self.btnInfo = tmp
  140. tmp.button = tmp:GetComponent(Enum.TypeInfo.Button)
  141. end
  142. ---@private
  143. function UIREShopView:InitGenerate__7(Root, data)
  144. --[[
  145. UIAnimator/Window/TopView/ResourceBox
  146. --]]
  147. local tmp = Root:Find("UIAnimator/Window/TopView/ResourceBox").gameObject
  148. if tolua.getpeer(tmp) == nil then
  149. tolua.setpeer(tmp, {})
  150. end
  151. self.resourceBox = tmp
  152. end
  153. ---@private
  154. function UIREShopView:InitGenerate__8(Root, data)
  155. --[[
  156. UIAnimator/Window/TopView/ResourceBox/ShopCurrencyItem
  157. --]]
  158. local tmp = Root:Find("UIAnimator/Window/TopView/ResourceBox/ShopCurrencyItem").gameObject
  159. if tolua.getpeer(tmp) == nil then
  160. tolua.setpeer(tmp, {})
  161. end
  162. self.shopCurrencyItem = CommonUtil.BindGridViewItem2LuaStatic("ShopCurrencyItem", tmp)
  163. self.shopCurrencyItem.prefabName = "ShopCurrencyItem"
  164. end
  165. ---@private
  166. function UIREShopView:InitGenerate__9(Root, data)
  167. --[[
  168. UIAnimator/Window/TopView/RedEnvelope
  169. --]]
  170. local tmp = Root:Find("UIAnimator/Window/TopView/RedEnvelope").gameObject
  171. if tolua.getpeer(tmp) == nil then
  172. tolua.setpeer(tmp, {})
  173. end
  174. self.redEnvelope = tmp
  175. end
  176. ---@private
  177. function UIREShopView:InitGenerate__10(Root, data)
  178. --[[
  179. UIAnimator/Window/TopView/RedEnvelope/Desc
  180. --]]
  181. local tmp = Root:Find("UIAnimator/Window/TopView/RedEnvelope/Desc").gameObject
  182. if tolua.getpeer(tmp) == nil then
  183. tolua.setpeer(tmp, {})
  184. end
  185. self.redEnvelope.desc = tmp
  186. tmp.text = tmp:GetComponent(Enum.TypeInfo.Text)
  187. end
  188. ---@private
  189. function UIREShopView:InitGenerate__11(Root, data)
  190. --[[
  191. UIAnimator/Window/TopView/RedEnvelope/BtnSure
  192. --]]
  193. local tmp = Root:Find("UIAnimator/Window/TopView/RedEnvelope/BtnSure").gameObject
  194. if tolua.getpeer(tmp) == nil then
  195. tolua.setpeer(tmp, {})
  196. end
  197. self.redEnvelope.btnSure = tmp
  198. tmp.button = tmp:GetComponent(Enum.TypeInfo.Button)
  199. end
  200. ---@private
  201. function UIREShopView:GenerateDestroy()
  202. if tolua.getpeer(self.redEnvelope.btnSure) ~= nil then
  203. tolua.setpeer(self.redEnvelope.btnSure, nil)
  204. end
  205. if tolua.getpeer(self.redEnvelope.desc) ~= nil then
  206. tolua.setpeer(self.redEnvelope.desc, nil)
  207. end
  208. if tolua.getpeer(self.uIAnimator) ~= nil then
  209. tolua.setpeer(self.uIAnimator, nil)
  210. end
  211. self.uIAnimator = nil
  212. if tolua.getpeer(self.AnyBtn) ~= nil then
  213. tolua.setpeer(self.AnyBtn, nil)
  214. end
  215. self.AnyBtn = nil
  216. if tolua.getpeer(self.goodsScrollView) ~= nil then
  217. tolua.setpeer(self.goodsScrollView, nil)
  218. end
  219. self.goodsScrollView = nil
  220. if self.runeShopGoodsItem.GenerateDestroy ~= nil then
  221. self.runeShopGoodsItem:GenerateDestroy()
  222. end
  223. if tolua.getpeer(self.runeShopGoodsItem) ~= nil then
  224. tolua.setpeer(self.runeShopGoodsItem, nil)
  225. end
  226. self.runeShopGoodsItem = nil
  227. if tolua.getpeer(self.btnClose) ~= nil then
  228. tolua.setpeer(self.btnClose, nil)
  229. end
  230. self.btnClose = nil
  231. if tolua.getpeer(self.btnInfo) ~= nil then
  232. tolua.setpeer(self.btnInfo, nil)
  233. end
  234. self.btnInfo = nil
  235. if tolua.getpeer(self.resourceBox) ~= nil then
  236. tolua.setpeer(self.resourceBox, nil)
  237. end
  238. self.resourceBox = nil
  239. if self.shopCurrencyItem.GenerateDestroy ~= nil then
  240. self.shopCurrencyItem:GenerateDestroy()
  241. end
  242. if tolua.getpeer(self.shopCurrencyItem) ~= nil then
  243. tolua.setpeer(self.shopCurrencyItem, nil)
  244. end
  245. self.shopCurrencyItem = nil
  246. if tolua.getpeer(self.redEnvelope) ~= nil then
  247. tolua.setpeer(self.redEnvelope, nil)
  248. end
  249. self.redEnvelope = nil
  250. self.transform = nil
  251. self.gameObject = nil
  252. self.inited = false
  253. end
  254. return UIREShopView