UIGuildChangeBadgeView_Generate.lua 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152
  1. ---@class UIGuildChangeBadge__Generate_usedBtn_text
  2. ---@field public gameObject UnityEngine.GameObject
  3. ---@field public text TMPro.TextMeshProUGUI
  4. ---@class UIGuildChangeBadge__Generate_usedBtn
  5. ---@field public gameObject UnityEngine.GameObject
  6. ---@field public button UnityEngine.UI.Button
  7. ---@field public text UIGuildChangeBadge__Generate_usedBtn_text
  8. ---@class UIGuildChangeBadge__Generate_changeList
  9. ---@field public gameObject UnityEngine.GameObject
  10. ---@field public loopVerticalScrollRect UnityEngine.UI.LoopVerticalScrollRect
  11. ---@class UIGuildChangeBadge__Generate_btnClose
  12. ---@field public gameObject UnityEngine.GameObject
  13. ---@field public button UnityEngine.UI.Button
  14. ---@class UIGuildChangeBadge__Generate_AnyBtn
  15. ---@field public gameObject UnityEngine.GameObject
  16. ---@field public button UnityEngine.UI.Button
  17. ---@class UIGuildChangeBadge__Generate
  18. ---@field private gameObject UnityEngine.GameObject
  19. ---@field private transform UnityEngine.Transform
  20. ---@field private AnyBtn UIGuildChangeBadge__Generate_AnyBtn
  21. ---@field private btnClose UIGuildChangeBadge__Generate_btnClose
  22. ---@field private changeList UIGuildChangeBadge__Generate_changeList
  23. ---@field private usedBtn UIGuildChangeBadge__Generate_usedBtn
  24. local UIGuildChangeBadgeView = class("UIGuildChangeBadgeView", require("UIViewBase"))
  25. function UIGuildChangeBadgeView:ctor()
  26. end
  27. ---@private
  28. function UIGuildChangeBadgeView:SetActive(result)
  29. self.gameObject:SetActive(result)
  30. end
  31. ---@private
  32. function UIGuildChangeBadgeView:InitGenerate(Root, data)
  33. self.transform = Root
  34. self.inited = true
  35. if self.super.Init then
  36. self.super.Init(self)
  37. end
  38. local tmp
  39. self:InitGenerate__1(Root,data)
  40. self:InitGenerate__2(Root,data)
  41. self:InitGenerate__3(Root,data)
  42. self:InitGenerate__4(Root,data)
  43. self:InitGenerate__5(Root,data)
  44. end
  45. ---@private
  46. function UIGuildChangeBadgeView:InitGenerate__1(Root, data)
  47. --[[
  48. UIAnimator/Alpha
  49. --]]
  50. local tmp = Root:Find("UIAnimator/Alpha").gameObject
  51. if tolua.getpeer(tmp) == nil then
  52. tolua.setpeer(tmp, {})
  53. end
  54. self.AnyBtn = tmp
  55. tmp.button = tmp:GetComponent(Enum.TypeInfo.Button)
  56. end
  57. ---@private
  58. function UIGuildChangeBadgeView:InitGenerate__2(Root, data)
  59. --[[
  60. UIAnimator/Window/CloseBox/BtnClose
  61. --]]
  62. local tmp = Root:Find("UIAnimator/Window/CloseBox/BtnClose").gameObject
  63. if tolua.getpeer(tmp) == nil then
  64. tolua.setpeer(tmp, {})
  65. end
  66. self.btnClose = tmp
  67. tmp.button = tmp:GetComponent(Enum.TypeInfo.Button)
  68. end
  69. ---@private
  70. function UIGuildChangeBadgeView:InitGenerate__3(Root, data)
  71. --[[
  72. UIAnimator/Window/ChangeList
  73. --]]
  74. local tmp = Root:Find("UIAnimator/Window/ChangeList").gameObject
  75. if tolua.getpeer(tmp) == nil then
  76. tolua.setpeer(tmp, {})
  77. end
  78. self.changeList = tmp
  79. tmp.loopVerticalScrollRect = tmp:GetComponent(Enum.TypeInfo.LoopVerticalScrollRect)
  80. end
  81. ---@private
  82. function UIGuildChangeBadgeView:InitGenerate__4(Root, data)
  83. --[[
  84. UIAnimator/Window/Bottom/UsedBtn
  85. --]]
  86. local tmp = Root:Find("UIAnimator/Window/Bottom/UsedBtn").gameObject
  87. if tolua.getpeer(tmp) == nil then
  88. tolua.setpeer(tmp, {})
  89. end
  90. self.usedBtn = tmp
  91. tmp.button = tmp:GetComponent(Enum.TypeInfo.Button)
  92. end
  93. ---@private
  94. function UIGuildChangeBadgeView:InitGenerate__5(Root, data)
  95. --[[
  96. UIAnimator/Window/Bottom/UsedBtn/Content/Text
  97. --]]
  98. local tmp = Root:Find("UIAnimator/Window/Bottom/UsedBtn/Content/Text").gameObject
  99. if tolua.getpeer(tmp) == nil then
  100. tolua.setpeer(tmp, {})
  101. end
  102. self.usedBtn.text = tmp
  103. tmp.text = tmp:GetComponent(Enum.TypeInfo.TextMeshProUGUI)
  104. end
  105. ---@private
  106. function UIGuildChangeBadgeView:GenerateDestroy()
  107. if tolua.getpeer(self.usedBtn.text) ~= nil then
  108. tolua.setpeer(self.usedBtn.text, nil)
  109. end
  110. if tolua.getpeer(self.AnyBtn) ~= nil then
  111. tolua.setpeer(self.AnyBtn, nil)
  112. end
  113. self.AnyBtn = nil
  114. if tolua.getpeer(self.btnClose) ~= nil then
  115. tolua.setpeer(self.btnClose, nil)
  116. end
  117. self.btnClose = nil
  118. if tolua.getpeer(self.changeList) ~= nil then
  119. tolua.setpeer(self.changeList, nil)
  120. end
  121. self.changeList = nil
  122. if tolua.getpeer(self.usedBtn) ~= nil then
  123. tolua.setpeer(self.usedBtn, nil)
  124. end
  125. self.usedBtn = nil
  126. self.transform = nil
  127. self.gameObject = nil
  128. self.inited = false
  129. end
  130. return UIGuildChangeBadgeView