UIChipProduceNoticeCtr.lua 723 B

123456789101112131415161718192021222324252627282930313233343536
  1. local UIChipProduceNoticeCtr = class("UIChipProduceNoticeCtr", require("UICtrBase"))
  2. function UIChipProduceNoticeCtr:Init(view)
  3. self.view = view
  4. end
  5. function UIChipProduceNoticeCtr:SetData(data)
  6. self.asyncIdx = 0
  7. if data == nil then return end
  8. self.data = data
  9. end
  10. function UIChipProduceNoticeCtr:GetAsyncIdx()
  11. self.asyncIdx = self.asyncIdx + 1
  12. return self.asyncIdx
  13. end
  14. function UIChipProduceNoticeCtr:GetData()
  15. return self.data
  16. end
  17. function UIChipProduceNoticeCtr:OnDispose()
  18. self.data = nil
  19. self.view = nil
  20. end
  21. function UIChipProduceNoticeCtr:SureDecompose()
  22. self.data[2](self.data[1])
  23. end
  24. function UIChipProduceNoticeCtr:CancelDecompose()
  25. self.data[3](self.data[1])
  26. end
  27. return UIChipProduceNoticeCtr