UIChat页面:支持Chat不同的消息类型

This commit is contained in:
fatiao 2025-09-04 19:44:20 +08:00
parent 933f58c963
commit cf8d0119a4
8 changed files with 4244 additions and 3907 deletions

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -1021,6 +1021,11 @@ local Enum = {
ChatSubType = {
None = 0,
Expedition = 1,
Text = 2, --文本消息
Gift = 3, --礼物消息
Date = 4, --约会消息
Image = 5, --图片消息
Hongbao = 6, --红包消息
},
ExpeditionHelpSource = {

View File

@ -1,18 +1,105 @@
local ChatContentItemCtr = {}
local TaskJumpCtr = require("Common/TaskJumpCtr")
--[[
Enum.ChatSubType = {
None = 0,
Expedition = 1,
Text = 2, --文本消息
Gift = 3, --礼物消息
Date = 4, --约会消息
Image = 5, --图片消息
Hongbao = 6, --红包消息
},
Enum.ChatSystemType = {
Loggedin = 0,
PassMap = 1,
Hero = 2,
Box = 3,
Item = 4,
ArenaWinStreak = 5,
WorldBoss = 6,
Guild = 7,
Competition = 8, --赛季系
ActCollection = 9,
TurnWheelPrize = 10, --播报三赛季转盘获得
GoddessLike = 11,
StarDivine = 12, --占星季播报
ItemExchange = 13, --兑换活动播报
ActivityWheel = 14, --活动转盘播报
GuildDemonBoss = 15, -- 公会魔王BOSS播报
IdolGiftBroad = 16, -- 偶像馈赠播报
TimeLimitDel = 100,
}
itemData格式type 6WorldBoss
{
"isSystem": true,
"nickname": "",
"paramIds": [
16,
0
],
"sendTime": "1753858800",
"sendTime64": "1753858800267",
"type": 6
}
itemData格式type 2Hero
{
"fromData": {
"headFrameId": 300,
"imgId": "Heads/head_100102",
"jobId": 10010,
"level": 42,
"nickname": "",
"sex": 2,
"titleId": 0,
"uid": "7491506103437492257",
"vipLv": 0
},
"message": {
"message": "[GIFT-2]",
"sendTime64": "1756966829316",
"subType": 0,
"used": false
},
"targetId": "0",
"type": 2
}
]]
function ChatContentItemCtr:SetData(wnd, itemLua, itemData, enterType, onClickOwner, onClickCB)
PrintJson("TAG-ChatContentItemCtr", itemData)
if itemData.isSystem then
-- {"isSystem":true,"nickname":"ChatNotice03","sendTime":0,"type":0}
--local enterType = Enum.ItemIEnterType.System
itemLua.l:SetActive(true)
itemLua.r:SetActive(false)
local contentStr = "System Message"
itemLua.l_Nickname.text.text = "System"
itemLua.l_ContentText.symbolText.text = contentStr
local contentNodes = {
["L"..Enum.ChatSubType.None] = itemLua.leftNode.contentText,
["L"..Enum.ChatSubType.Text] = itemLua.leftNode.contentText,
["L"..Enum.ChatSubType.Gift] = itemLua.leftNode.contentGift,
["L"..Enum.ChatSubType.Date] = itemLua.leftNode.contentDate,
["L"..Enum.ChatSubType.Image] = itemLua.leftNode.contentImage,
["L"..Enum.ChatSubType.Hongbao] = itemLua.leftNode.contentHongbao,
["R"..Enum.ChatSubType.None] = itemLua.rightNode.contentText,
["R"..Enum.ChatSubType.Text] = itemLua.rightNode.contentText,
["R"..Enum.ChatSubType.Gift] = itemLua.rightNode.contentGift,
["R"..Enum.ChatSubType.Date] = itemLua.rightNode.contentDate,
["R"..Enum.ChatSubType.Image] = itemLua.rightNode.contentImage,
["R"..Enum.ChatSubType.Hongbao] = itemLua.rightNode.contentHongbao,
}
for k, v in pairs(contentNodes) do
v:SetActive(false)
end
local length = 40 + StringUtil.GetTextLeng(itemLua.l_ContentText.symbolText, contentStr)
-- 1. 系统消息
if itemData.isSystem then
itemLua.leftNode:SetActive(true)
itemLua.rightNode:SetActive(false)
contentNodes["L"..Enum.ChatSubType.Text]:SetActive(true)
contentNodes["R"..Enum.ChatSubType.Text]:SetActive(true)
local contentStr = "System Message"
itemLua.leftNode.nickname.text.text = "System"
itemLua.leftNode.contentText.chatText.symbolText.text = contentStr
local length = 40 + StringUtil.GetTextLeng(itemLua.leftNode.contentText.chatText.symbolText, contentStr)
local emojis = ManagerContainer.CfgMgr:GetEmojiCfg()
local regexPattern = "%[e%d+%]"
for k, v in string.gmatch(contentStr, regexPattern) do
@ -24,17 +111,31 @@ function ChatContentItemCtr:SetData(wnd, itemLua, itemData, enterType, onClickOw
local width = math.min(length, 700)
local height = math.max(40 + 40*(1 + length/700), 120)
itemLua.layoutElement.preferredHeight = 40 + height
itemLua.l_Content.rectTransform.sizeDelta = Vector2(width, height)
else
--local enterType = Enum.ItemIEnterType.Hero
local contentStr = itemData.message.message
itemLua.leftNode.contentText.rectTransform.sizeDelta = Vector2(width, height)
return
end
-- 2. 世界聊天、工会聊天、私聊
if itemData.type == Enum.ChatSystemType.Hero or itemData.type == Enum.ChatSystemType.WorldBoss or itemData.type == Enum.ChatSystemType.Guild then
-- test: itemData.message.subType = Enum.ChatSubType.Image
local userUid = ManagerContainer.DataMgr.UserData:GetUserId()
local isLeft = itemData.fromData.uid ~= tostring(userUid)
itemLua.l:SetActive(isLeft)
itemLua.r:SetActive(not isLeft)
if isLeft then
itemLua.l_ContentText.symbolText.text = contentStr
local length = 40 + StringUtil.GetTextLeng(itemLua.l_ContentText.symbolText, contentStr)
itemLua.leftNode:SetActive(isLeft)
itemLua.rightNode:SetActive(not isLeft)
contentNodes["L"..itemData.message.subType]:SetActive(true)
contentNodes["R"..itemData.message.subType]:SetActive(true)
-- 2.1 文本消息
if itemData.message.subType == Enum.ChatSubType.Text then
local contentStr = itemData.message.message
local currContentTextNode
if isLeft then
currContentTextNode = itemLua.leftNode.contentText
else
currContentTextNode = itemLua.rightNode.contentText
end
currContentTextNode.chatText.symbolText.text = contentStr
local length = 40 + StringUtil.GetTextLeng(currContentTextNode.chatText.symbolText, contentStr)
local emojis = ManagerContainer.CfgMgr:GetEmojiCfg()
local regexPattern = "%[e%d+%]"
for k, v in string.gmatch(contentStr, regexPattern) do
@ -46,23 +147,57 @@ function ChatContentItemCtr:SetData(wnd, itemLua, itemData, enterType, onClickOw
local width = math.min(length, 700)
local height = math.max(40 + 40*(1 + length/700), 120)
itemLua.layoutElement.preferredHeight = 40 + height
itemLua.l_Content.rectTransform.sizeDelta = Vector2(width, height)
else
--PrintJson("TAG-ChatContentItemCtr Right", itemData)
itemLua.r_ContentText.symbolText.text = contentStr
local length = 40 + StringUtil.GetTextLeng(itemLua.r_ContentText.symbolText, contentStr)
local emojis = ManagerContainer.CfgMgr:GetEmojiCfg()
local regexPattern = "%[e%d+%]"
for k, v in string.gmatch(contentStr, regexPattern) do
local num = tonumber(string.match(k, '%d+'))
if num < #emojis then
length = length + 20
end
currContentTextNode.rectTransform.sizeDelta = Vector2(width, height)
-- if isLeft then
-- currContentTextNode.chatText.symbolText.text = contentStr
-- local length = 40 + StringUtil.GetTextLeng(currContentTextNode.chatText.symbolText, contentStr)
-- local emojis = ManagerContainer.CfgMgr:GetEmojiCfg()
-- local regexPattern = "%[e%d+%]"
-- for k, v in string.gmatch(contentStr, regexPattern) do
-- local num = tonumber(string.match(k, '%d+'))
-- if num < #emojis then
-- length = length + 20
-- end
-- end
-- local width = math.min(length, 700)
-- local height = math.max(40 + 40*(1 + length/700), 120)
-- itemLua.layoutElement.preferredHeight = 40 + height
-- currContentTextNode.rectTransform.sizeDelta = Vector2(width, height)
-- else
-- --PrintJson("TAG-ChatContentItemCtr Right", itemData)
-- itemLua.rightNode.contentText.symbolText.text = contentStr
-- local length = 40 + StringUtil.GetTextLeng(itemLua.rightNode.contentText.symbolText, contentStr)
-- local emojis = ManagerContainer.CfgMgr:GetEmojiCfg()
-- local regexPattern = "%[e%d+%]"
-- for k, v in string.gmatch(contentStr, regexPattern) do
-- local num = tonumber(string.match(k, '%d+'))
-- if num < #emojis then
-- length = length + 20
-- end
-- end
-- local width = math.min(length, 700)
-- local height = math.max(40 + 40*(1 + length/700), 120)
-- itemLua.layoutElement.preferredHeight = 40 + height
-- itemLua.rightNode.contentText.rectTransform.sizeDelta = Vector2(width, height)
-- end
-- 2.2 礼物消息
elseif itemData.message.subType == Enum.ChatSubType.Gift then
-- 2.3 约会消息
elseif itemData.message.subType == Enum.ChatSubType.Date then
-- 2.4 图片消息
elseif itemData.message.subType == Enum.ChatSubType.Image then
itemLua.rectTransform.sizeDelta = Vector2(itemLua.rectTransform.sizeDelta.x, 500)
itemLua.layoutElement.preferredHeight = 500
local currContentImageNode
if isLeft then
currContentImageNode = itemLua.leftNode.contentImage
else
currContentImageNode = itemLua.rightNode.contentImage
end
local width = math.min(length, 700)
local height = math.max(40 + 40*(1 + length/700), 120)
itemLua.layoutElement.preferredHeight = 40 + height
itemLua.r_Content.rectTransform.sizeDelta = Vector2(width, height)
currContentImageNode.rectTransform.sizeDelta = Vector2(400, 400)
end
end
--[[

View File

@ -1,40 +1,101 @@
---@class ChatContentItem__Generate_r_ContentText
---@class ChatContentItem__Generate_rightNode_contentDate
---@field public gameObject UnityEngine.GameObject
---@field public rectTransform UnityEngine.RectTransform
---@field public image UnityEngine.GameObject
---@class ChatContentItem__Generate_rightNode_contentGift
---@field public gameObject UnityEngine.GameObject
---@field public rectTransform UnityEngine.RectTransform
---@field public image UnityEngine.GameObject
---@class ChatContentItem__Generate_rightNode_contentImage
---@field public gameObject UnityEngine.GameObject
---@field public rectTransform UnityEngine.RectTransform
---@field public image UnityEngine.GameObject
---@class ChatContentItem__Generate_rightNode_contentHongbao
---@field public gameObject UnityEngine.GameObject
---@field public text UnityEngine.GameObject
---@class ChatContentItem__Generate_rightNode_contentText_chatText
---@field public gameObject UnityEngine.GameObject
---@field public symbolText WXB.SymbolText
---@class ChatContentItem__Generate_r_Content
---@class ChatContentItem__Generate_rightNode_contentText
---@field public gameObject UnityEngine.GameObject
---@field public rectTransform UnityEngine.RectTransform
---@field public chatText ChatContentItem__Generate_rightNode_contentText_chatText
---@class ChatContentItem__Generate_l_ContentText
---@class ChatContentItem__Generate_rightNode_headIconNode
---@field public gameObject UnityEngine.GameObject
---@field public headIcon UnityEngine.GameObject
---@class ChatContentItem__Generate_rightNode
---@field public gameObject UnityEngine.GameObject
---@field public headIconNode ChatContentItem__Generate_rightNode_headIconNode
---@field public contentText ChatContentItem__Generate_rightNode_contentText
---@field public contentHongbao ChatContentItem__Generate_rightNode_contentHongbao
---@field public contentImage ChatContentItem__Generate_rightNode_contentImage
---@field public contentGift ChatContentItem__Generate_rightNode_contentGift
---@field public contentDate ChatContentItem__Generate_rightNode_contentDate
---@class ChatContentItem__Generate_leftNode_contentDate
---@field public gameObject UnityEngine.GameObject
---@field public rectTransform UnityEngine.RectTransform
---@field public image UnityEngine.GameObject
---@class ChatContentItem__Generate_leftNode_contentGift
---@field public gameObject UnityEngine.GameObject
---@field public rectTransform UnityEngine.RectTransform
---@field public image UnityEngine.GameObject
---@class ChatContentItem__Generate_leftNode_contentImage
---@field public gameObject UnityEngine.GameObject
---@field public rectTransform UnityEngine.RectTransform
---@field public image UnityEngine.GameObject
---@class ChatContentItem__Generate_leftNode_contentHongbao
---@field public gameObject UnityEngine.GameObject
---@field public hongbaoText UnityEngine.GameObject
---@class ChatContentItem__Generate_leftNode_contentText_chatText
---@field public gameObject UnityEngine.GameObject
---@field public symbolText WXB.SymbolText
---@class ChatContentItem__Generate_l_Content
---@class ChatContentItem__Generate_leftNode_contentText
---@field public gameObject UnityEngine.GameObject
---@field public rectTransform UnityEngine.RectTransform
---@field public chatText ChatContentItem__Generate_leftNode_contentText_chatText
---@class ChatContentItem__Generate_l_Nickname
---@class ChatContentItem__Generate_leftNode_nickname
---@field public gameObject UnityEngine.GameObject
---@field public text TMPro.TextMeshProUGUI
---@class ChatContentItem__Generate_l_HeadIcon
---@class ChatContentItem__Generate_leftNode_headIconNode_headIcon
---@field public gameObject UnityEngine.GameObject
---@field public image UnityEngine.UI.Image
---@class ChatContentItem__Generate_leftNode_headIconNode
---@field public gameObject UnityEngine.GameObject
---@field public headIcon ChatContentItem__Generate_leftNode_headIconNode_headIcon
---@class ChatContentItem__Generate_leftNode
---@field public gameObject UnityEngine.GameObject
---@field public headIconNode ChatContentItem__Generate_leftNode_headIconNode
---@field public nickname ChatContentItem__Generate_leftNode_nickname
---@field public contentText ChatContentItem__Generate_leftNode_contentText
---@field public contentHongbao ChatContentItem__Generate_leftNode_contentHongbao
---@field public contentImage ChatContentItem__Generate_leftNode_contentImage
---@field public contentGift ChatContentItem__Generate_leftNode_contentGift
---@field public contentDate ChatContentItem__Generate_leftNode_contentDate
---@class ChatContentItem__Generate
---@field private gameObject UnityEngine.GameObject
---@field private transform UnityEngine.Transform
---@field private rectTransform UnityEngine.RectTransform
---@field private layoutElement UnityEngine.UI.LayoutElement
---@field private l UnityEngine.GameObject
---@field private l_HeadIcon ChatContentItem__Generate_l_HeadIcon
---@field private l_Nickname ChatContentItem__Generate_l_Nickname
---@field private l_Content ChatContentItem__Generate_l_Content
---@field private l_ContentText ChatContentItem__Generate_l_ContentText
---@field private r UnityEngine.GameObject
---@field private r_Content ChatContentItem__Generate_r_Content
---@field private r_ContentText ChatContentItem__Generate_r_ContentText
---@field private leftNode ChatContentItem__Generate_leftNode
---@field private rightNode ChatContentItem__Generate_rightNode
local ChatContentItemView = class("ChatContentItemView")
function ChatContentItemView:ctor()
@ -60,6 +121,25 @@ function ChatContentItemView:InitGenerate(Root, data)
self:InitGenerate__7(Root,data)
self:InitGenerate__8(Root,data)
self:InitGenerate__9(Root,data)
self:InitGenerate__10(Root,data)
self:InitGenerate__11(Root,data)
self:InitGenerate__12(Root,data)
self:InitGenerate__13(Root,data)
self:InitGenerate__14(Root,data)
self:InitGenerate__15(Root,data)
self:InitGenerate__16(Root,data)
self:InitGenerate__17(Root,data)
self:InitGenerate__18(Root,data)
self:InitGenerate__19(Root,data)
self:InitGenerate__20(Root,data)
self:InitGenerate__21(Root,data)
self:InitGenerate__22(Root,data)
self:InitGenerate__23(Root,data)
self:InitGenerate__24(Root,data)
self:InitGenerate__25(Root,data)
self:InitGenerate__26(Root,data)
self:InitGenerate__27(Root,data)
self:InitGenerate__28(Root,data)
end
@ -78,145 +158,436 @@ end
---@private
function ChatContentItemView:InitGenerate__2(Root, data)
--[[
L
LeftNode
--]]
local tmp = Root:Find("L").gameObject
local tmp = Root:Find("LeftNode").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.l = tmp
self.leftNode = tmp
end
---@private
function ChatContentItemView:InitGenerate__3(Root, data)
--[[
L/L_HeadIcon/L_HeadIcon
LeftNode/HeadIconNode
--]]
local tmp = Root:Find("L/L_HeadIcon/L_HeadIcon").gameObject
local tmp = Root:Find("LeftNode/HeadIconNode").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.l_HeadIcon = tmp
tmp.image = tmp:GetComponent(Enum.TypeInfo.Image)
self.leftNode.headIconNode = tmp
end
---@private
function ChatContentItemView:InitGenerate__4(Root, data)
--[[
L/L_Nickname
LeftNode/HeadIconNode/HeadIcon
--]]
local tmp = Root:Find("L/L_Nickname").gameObject
local tmp = Root:Find("LeftNode/HeadIconNode/HeadIcon").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.l_Nickname = tmp
self.leftNode.headIconNode.headIcon = tmp
tmp.text = tmp:GetComponent(Enum.TypeInfo.TextMeshProUGUI)
tmp.image = tmp:GetComponent(Enum.TypeInfo.Image)
end
---@private
function ChatContentItemView:InitGenerate__5(Root, data)
--[[
L/L_Content
LeftNode/Nickname
--]]
local tmp = Root:Find("L/L_Content").gameObject
local tmp = Root:Find("LeftNode/Nickname").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.l_Content = tmp
self.leftNode.nickname = tmp
tmp.rectTransform = tmp:GetComponent(Enum.TypeInfo.RectTransform)
tmp.text = tmp:GetComponent(Enum.TypeInfo.TextMeshProUGUI)
end
---@private
function ChatContentItemView:InitGenerate__6(Root, data)
--[[
L/L_Content/L_ContentText
LeftNode/ContentText
--]]
local tmp = Root:Find("L/L_Content/L_ContentText").gameObject
local tmp = Root:Find("LeftNode/ContentText").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.l_ContentText = tmp
tmp.symbolText = tmp:GetComponent(Enum.TypeInfo.SymbolText)
end
---@private
function ChatContentItemView:InitGenerate__7(Root, data)
--[[
R
--]]
local tmp = Root:Find("R").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.r = tmp
end
---@private
function ChatContentItemView:InitGenerate__8(Root, data)
--[[
R/R_Content
--]]
local tmp = Root:Find("R/R_Content").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.r_Content = tmp
self.leftNode.contentText = tmp
tmp.rectTransform = tmp:GetComponent(Enum.TypeInfo.RectTransform)
end
---@private
function ChatContentItemView:InitGenerate__9(Root, data)
function ChatContentItemView:InitGenerate__7(Root, data)
--[[
R/R_Content/R_ContentText
LeftNode/ContentText/ChatText
--]]
local tmp = Root:Find("R/R_Content/R_ContentText").gameObject
local tmp = Root:Find("LeftNode/ContentText/ChatText").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.r_ContentText = tmp
self.leftNode.contentText.chatText = tmp
tmp.symbolText = tmp:GetComponent(Enum.TypeInfo.SymbolText)
end
---@private
function ChatContentItemView:InitGenerate__8(Root, data)
--[[
LeftNode/ContentHongbao
--]]
local tmp = Root:Find("LeftNode/ContentHongbao").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.leftNode.contentHongbao = tmp
end
---@private
function ChatContentItemView:InitGenerate__9(Root, data)
--[[
LeftNode/ContentHongbao/HongbaoText
--]]
local tmp = Root:Find("LeftNode/ContentHongbao/HongbaoText").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.leftNode.contentHongbao.hongbaoText = tmp
end
---@private
function ChatContentItemView:InitGenerate__10(Root, data)
--[[
LeftNode/ContentImage
--]]
local tmp = Root:Find("LeftNode/ContentImage").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.leftNode.contentImage = tmp
tmp.rectTransform = tmp:GetComponent(Enum.TypeInfo.RectTransform)
end
---@private
function ChatContentItemView:InitGenerate__11(Root, data)
--[[
LeftNode/ContentImage/Image
--]]
local tmp = Root:Find("LeftNode/ContentImage/Image").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.leftNode.contentImage.image = tmp
end
---@private
function ChatContentItemView:InitGenerate__12(Root, data)
--[[
LeftNode/ContentGift
--]]
local tmp = Root:Find("LeftNode/ContentGift").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.leftNode.contentGift = tmp
tmp.rectTransform = tmp:GetComponent(Enum.TypeInfo.RectTransform)
end
---@private
function ChatContentItemView:InitGenerate__13(Root, data)
--[[
LeftNode/ContentGift/Image
--]]
local tmp = Root:Find("LeftNode/ContentGift/Image").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.leftNode.contentGift.image = tmp
end
---@private
function ChatContentItemView:InitGenerate__14(Root, data)
--[[
LeftNode/ContentDate
--]]
local tmp = Root:Find("LeftNode/ContentDate").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.leftNode.contentDate = tmp
tmp.rectTransform = tmp:GetComponent(Enum.TypeInfo.RectTransform)
end
---@private
function ChatContentItemView:InitGenerate__15(Root, data)
--[[
LeftNode/ContentDate/Image
--]]
local tmp = Root:Find("LeftNode/ContentDate/Image").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.leftNode.contentDate.image = tmp
end
---@private
function ChatContentItemView:InitGenerate__16(Root, data)
--[[
RightNode
--]]
local tmp = Root:Find("RightNode").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.rightNode = tmp
end
---@private
function ChatContentItemView:InitGenerate__17(Root, data)
--[[
RightNode/HeadIconNode
--]]
local tmp = Root:Find("RightNode/HeadIconNode").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.rightNode.headIconNode = tmp
end
---@private
function ChatContentItemView:InitGenerate__18(Root, data)
--[[
RightNode/HeadIconNode/HeadIcon
--]]
local tmp = Root:Find("RightNode/HeadIconNode/HeadIcon").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.rightNode.headIconNode.headIcon = tmp
end
---@private
function ChatContentItemView:InitGenerate__19(Root, data)
--[[
RightNode/ContentText
--]]
local tmp = Root:Find("RightNode/ContentText").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.rightNode.contentText = tmp
tmp.rectTransform = tmp:GetComponent(Enum.TypeInfo.RectTransform)
end
---@private
function ChatContentItemView:InitGenerate__20(Root, data)
--[[
RightNode/ContentText/ChatText
--]]
local tmp = Root:Find("RightNode/ContentText/ChatText").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.rightNode.contentText.chatText = tmp
tmp.symbolText = tmp:GetComponent(Enum.TypeInfo.SymbolText)
end
---@private
function ChatContentItemView:InitGenerate__21(Root, data)
--[[
RightNode/ContentHongbao
--]]
local tmp = Root:Find("RightNode/ContentHongbao").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.rightNode.contentHongbao = tmp
end
---@private
function ChatContentItemView:InitGenerate__22(Root, data)
--[[
RightNode/ContentHongbao/Text
--]]
local tmp = Root:Find("RightNode/ContentHongbao/Text").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.rightNode.contentHongbao.text = tmp
end
---@private
function ChatContentItemView:InitGenerate__23(Root, data)
--[[
RightNode/ContentImage
--]]
local tmp = Root:Find("RightNode/ContentImage").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.rightNode.contentImage = tmp
tmp.rectTransform = tmp:GetComponent(Enum.TypeInfo.RectTransform)
end
---@private
function ChatContentItemView:InitGenerate__24(Root, data)
--[[
RightNode/ContentImage/Image
--]]
local tmp = Root:Find("RightNode/ContentImage/Image").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.rightNode.contentImage.image = tmp
end
---@private
function ChatContentItemView:InitGenerate__25(Root, data)
--[[
RightNode/ContentGift
--]]
local tmp = Root:Find("RightNode/ContentGift").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.rightNode.contentGift = tmp
tmp.rectTransform = tmp:GetComponent(Enum.TypeInfo.RectTransform)
end
---@private
function ChatContentItemView:InitGenerate__26(Root, data)
--[[
RightNode/ContentGift/Image
--]]
local tmp = Root:Find("RightNode/ContentGift/Image").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.rightNode.contentGift.image = tmp
end
---@private
function ChatContentItemView:InitGenerate__27(Root, data)
--[[
RightNode/ContentDate
--]]
local tmp = Root:Find("RightNode/ContentDate").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.rightNode.contentDate = tmp
tmp.rectTransform = tmp:GetComponent(Enum.TypeInfo.RectTransform)
end
---@private
function ChatContentItemView:InitGenerate__28(Root, data)
--[[
RightNode/ContentDate/Image
--]]
local tmp = Root:Find("RightNode/ContentDate/Image").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.rightNode.contentDate.image = tmp
end
---@private
function ChatContentItemView:GenerateDestroy()
if tolua.getpeer(self.l) ~= nil then
tolua.setpeer(self.l, nil)
if tolua.getpeer(self.rightNode.contentDate.image) ~= nil then
tolua.setpeer(self.rightNode.contentDate.image, nil)
end
self.l = nil
if tolua.getpeer(self.l_HeadIcon) ~= nil then
tolua.setpeer(self.l_HeadIcon, nil)
if tolua.getpeer(self.rightNode.contentDate) ~= nil then
tolua.setpeer(self.rightNode.contentDate, nil)
end
self.l_HeadIcon = nil
if tolua.getpeer(self.l_Nickname) ~= nil then
tolua.setpeer(self.l_Nickname, nil)
if tolua.getpeer(self.rightNode.contentGift.image) ~= nil then
tolua.setpeer(self.rightNode.contentGift.image, nil)
end
self.l_Nickname = nil
if tolua.getpeer(self.l_Content) ~= nil then
tolua.setpeer(self.l_Content, nil)
if tolua.getpeer(self.rightNode.contentGift) ~= nil then
tolua.setpeer(self.rightNode.contentGift, nil)
end
self.l_Content = nil
if tolua.getpeer(self.l_ContentText) ~= nil then
tolua.setpeer(self.l_ContentText, nil)
if tolua.getpeer(self.rightNode.contentImage.image) ~= nil then
tolua.setpeer(self.rightNode.contentImage.image, nil)
end
self.l_ContentText = nil
if tolua.getpeer(self.r) ~= nil then
tolua.setpeer(self.r, nil)
if tolua.getpeer(self.rightNode.contentImage) ~= nil then
tolua.setpeer(self.rightNode.contentImage, nil)
end
self.r = nil
if tolua.getpeer(self.r_Content) ~= nil then
tolua.setpeer(self.r_Content, nil)
if tolua.getpeer(self.rightNode.contentHongbao.text) ~= nil then
tolua.setpeer(self.rightNode.contentHongbao.text, nil)
end
self.r_Content = nil
if tolua.getpeer(self.r_ContentText) ~= nil then
tolua.setpeer(self.r_ContentText, nil)
if tolua.getpeer(self.rightNode.contentHongbao) ~= nil then
tolua.setpeer(self.rightNode.contentHongbao, nil)
end
self.r_ContentText = nil
if tolua.getpeer(self.rightNode.contentText.chatText) ~= nil then
tolua.setpeer(self.rightNode.contentText.chatText, nil)
end
if tolua.getpeer(self.rightNode.contentText) ~= nil then
tolua.setpeer(self.rightNode.contentText, nil)
end
if tolua.getpeer(self.rightNode.headIconNode.headIcon) ~= nil then
tolua.setpeer(self.rightNode.headIconNode.headIcon, nil)
end
if tolua.getpeer(self.rightNode.headIconNode) ~= nil then
tolua.setpeer(self.rightNode.headIconNode, nil)
end
if tolua.getpeer(self.leftNode.contentDate.image) ~= nil then
tolua.setpeer(self.leftNode.contentDate.image, nil)
end
if tolua.getpeer(self.leftNode.contentDate) ~= nil then
tolua.setpeer(self.leftNode.contentDate, nil)
end
if tolua.getpeer(self.leftNode.contentGift.image) ~= nil then
tolua.setpeer(self.leftNode.contentGift.image, nil)
end
if tolua.getpeer(self.leftNode.contentGift) ~= nil then
tolua.setpeer(self.leftNode.contentGift, nil)
end
if tolua.getpeer(self.leftNode.contentImage.image) ~= nil then
tolua.setpeer(self.leftNode.contentImage.image, nil)
end
if tolua.getpeer(self.leftNode.contentImage) ~= nil then
tolua.setpeer(self.leftNode.contentImage, nil)
end
if tolua.getpeer(self.leftNode.contentHongbao.hongbaoText) ~= nil then
tolua.setpeer(self.leftNode.contentHongbao.hongbaoText, nil)
end
if tolua.getpeer(self.leftNode.contentHongbao) ~= nil then
tolua.setpeer(self.leftNode.contentHongbao, nil)
end
if tolua.getpeer(self.leftNode.contentText.chatText) ~= nil then
tolua.setpeer(self.leftNode.contentText.chatText, nil)
end
if tolua.getpeer(self.leftNode.contentText) ~= nil then
tolua.setpeer(self.leftNode.contentText, nil)
end
if tolua.getpeer(self.leftNode.nickname) ~= nil then
tolua.setpeer(self.leftNode.nickname, nil)
end
if tolua.getpeer(self.leftNode.headIconNode.headIcon) ~= nil then
tolua.setpeer(self.leftNode.headIconNode.headIcon, nil)
end
if tolua.getpeer(self.leftNode.headIconNode) ~= nil then
tolua.setpeer(self.leftNode.headIconNode, nil)
end
if tolua.getpeer(self.leftNode) ~= nil then
tolua.setpeer(self.leftNode, nil)
end
self.leftNode = nil
if tolua.getpeer(self.rightNode) ~= nil then
tolua.setpeer(self.rightNode, nil)
end
self.rightNode = nil
self.transform = nil
self.gameObject = nil
self.inited = false

View File

@ -38,7 +38,6 @@ end
function UIChatView:AddEventListener()
ManagerContainer.LuaEventMgr:RegisterUIEvent(self.uiData.name, UIEventNames.REFRESH_WOLRD_CHAT, function()
--self:RefreshChatLayer1()
self:RefreshMessageTab()
self:RefreshChatLayer2(CONST_CHANNEL_WORLD)
end)
@ -61,6 +60,8 @@ end
function UIChatView:OnceInit()
self:InitEmojiPanel()
self:InitGiftWindow()
self:InitDateWindow()
self:InitPhotoWindow()
end
function UIChatView:Init()
@ -71,10 +72,9 @@ function UIChatView:Init()
-- end
self:SetToggleGroupStatus(channel)
self:OnChannelChange(nil, channel, true)
self.uiBase:AddButtonUniqueEventListener(self.layer1_TitleBarReturnBtn.button, self, self.OnClickReturnBtn)
self.uiBase:AddButtonUniqueEventListener(self.chatLayer2.titleBarReturnBtn.button, self, self.Layer2_OnClickReturnBtn)
self.uiBase:AddButtonUniqueEventListener(self.btnSendChat1.button, self, self.OnBtnSendChat1)
self.uiBase:AddButtonUniqueEventListener(self.chatLayer2.AnyBtn.button, self, self.OnChatLayer2AnyBtn)
self.uiBase:AddButtonUniqueEventListener(self.chatLayer2.btnSend.button, self, self.OnChatLayer2BtnSend)
self.currChatChannelId = "0"
self.tabViews = {
@ -101,10 +101,12 @@ function UIChatView:Init()
}
end
function UIChatView:OnBtnSendChat1()
LogError("UIChatView-OnBtnSendChat1: "..self.chatInputField1.inputField.text)
local content = self.chatInputField1.inputField.text
self.chatInputField1.inputField.text = ""
function UIChatView:OnChatLayer2BtnSend()
if self.chatLayer2.inputField.inputField.text == "" then return end
LogError("UIChatView-OnChatLayer2BtnSend: "..self.chatLayer2.inputField.inputField.text)
local content = self.chatLayer2.inputField.inputField.text
self.chatLayer2.inputField.inputField.text = ""
self.controller:SendChatReq(content, Enum.ChatSystemType.Hero)
end
@ -146,14 +148,122 @@ function UIChatView:InitEmojiPanel()
end
function UIChatView:InitGiftWindow()
local emojis = ManagerContainer.CfgMgr:GetEmojiCfg()
CommonUtil.LoopGridViewEleCreateNoItem(self,
self.chatLayer2.giftWindow.loopVerticalScrollRect,
emojis,
0,
self, function (owner, go, idx, logicData)
end)
local gifts = {
{id=1, name="A", icon="icon-1", num=1},
{id=2, name="B", icon="icon-1", num=1},
{id=3, name="C", icon="icon-1", num=1},
{id=4, name="D", icon="icon-1", num=1},
{id=5, name="E", icon="icon-1", num=1},
{id=6, name="F", icon="icon-1", num=1},
{id=7, name="G", icon="icon-1", num=1},
{id=8, name="I", icon="icon-1", num=1},
}
CommonUtil.LoopGridViewEleCreateNoItem(
self,
self.chatLayer2.giftWindow.loopVerticalScrollRect,
gifts,
0,
self,
function (owner, go, idx, logicData)
local uiTrigger = go:GetComponent(Enum.TypeInfo.UIEventTriggerListener)
uiTrigger.onClick = function() self:OnGiftClick(logicData.id) end
end
)
end
function UIChatView:ShowStoryWindow(storyDatas)
self.chatLayer2.storyWindow.loopVerticalScrollRect:ClearCells()
CommonUtil.LoopGridViewEleCreateNoItem(
self,
self.chatLayer2.storyWindow.loopVerticalScrollRect,
storyDatas,
0,
self,
function (owner, go, idx, logicData)
local txtTrans = go.transform:Find("Txt")
local txt = txtTrans:GetComponent(Enum.TypeInfo.TextMeshProUGUI)
txt.text = logicData.txt
local uiTrigger = go:GetComponent(Enum.TypeInfo.UIEventTriggerListener)
uiTrigger.onClick = function() self:OnStoryClick(logicData.id, logicData.txt) end
end
)
end
function UIChatView:InitDateWindow()
local dates = {
{id=1, name="A", icon="icon-1"},
{id=2, name="B", icon="icon-1"},
{id=3, name="C", icon="icon-1"},
{id=4, name="D", icon="icon-1"},
{id=5, name="E", icon="icon-1"},
{id=6, name="F", icon="icon-1"},
{id=7, name="G", icon="icon-1"},
{id=8, name="I", icon="icon-1"},
}
CommonUtil.LoopGridViewEleCreateNoItem(
self,
self.chatLayer2.dateWindow.loopVerticalScrollRect,
dates,
0,
self,
function (owner, go, idx, logicData)
local uiTrigger = go:GetComponent(Enum.TypeInfo.UIEventTriggerListener)
uiTrigger.onClick = function() self:OnDateClick(logicData.id) end
end
)
end
function UIChatView:InitPhotoWindow()
local photos = {
{id=1, name="A", icon="icon-1"},
{id=2, name="B", icon="icon-1"},
{id=3, name="C", icon="icon-1"},
{id=4, name="D", icon="icon-1"},
{id=5, name="E", icon="icon-1"},
{id=6, name="F", icon="icon-1"},
{id=7, name="G", icon="icon-1"},
{id=8, name="I", icon="icon-1"},
}
CommonUtil.LoopGridViewEleCreateNoItem(
self,
self.chatLayer2.photoWindow.loopVerticalScrollRect,
photos,
0,
self,
function (owner, go, idx, logicData)
local uiTrigger = go:GetComponent(Enum.TypeInfo.UIEventTriggerListener)
uiTrigger.onClick = function() self:OnPhotoClick(logicData.id) end
end
)
end
function UIChatView:OnPhotoClick(photoId)
LogError("OnPhotoClick: "..photoId)
local format = "[PHOTO-%s]"
self.chatLayer2.inputField.inputField.text = string.format(format, photoId)
self:CloseAllInputToolBarToggles()
end
function UIChatView:OnStoryClick(id, txt)
LogError("OnStoryClick: "..id)
self.chatLayer2.inputField.inputField.text = txt
self:CloseAllInputToolBarToggles()
end
function UIChatView:OnGiftClick(giftId)
LogError("OnGiftClick: "..giftId)
local format = "[GIFT-%s]"
self.chatLayer2.inputField.inputField.text = string.format(format, giftId)
self:CloseAllInputToolBarToggles()
end
function UIChatView:OnDateClick(dateId)
LogError("OnGiftClick: "..dateId)
local format = "[DATE-%s]"
self.chatLayer2.inputField.inputField.text = string.format(format, dateId)
self:CloseAllInputToolBarToggles()
end
function UIChatView:OnEmojiClick(idx)
@ -175,6 +285,10 @@ function UIChatView:OnEmojiClick(idx)
self:CloseAllInputToolBarToggles()
end
function UIChatView:ResetInputField()
self.chatLayer2.inputField.inputField.text = ""
end
function UIChatView:OnChannelChange(toggle, chatType, isOn)
if not isOn then return end
if self:IsSomeFrameCount('ChatChannelToggle') then
@ -203,7 +317,7 @@ function UIChatView:RemoveEventListener()
end
function UIChatView:OnBtnClose(button, params)
if self.emojiWindow1.activeSelf then
if self.chatLayer2.emojiWindow.activeSelf then
self:OnEmojiBgClick()
return
end
@ -211,7 +325,7 @@ function UIChatView:OnBtnClose(button, params)
end
function UIChatView:OnEmojiBgClick(button, params)
self.emojiWindow1:SetActive(not self.emojiWindow1.activeSelf)
self.chatLayer2.emojiWindow:SetActive(not self.chatLayer2.emojiWindow.activeSelf)
end
function UIChatView:OnBottomTabChange(toggle, tabType, isOn)
@ -723,10 +837,6 @@ end
function UIChatView:RefreshMeTab()
end
function UIChatView:OnClickReturnBtn()
self.chatLayer1:SetActive(false)
end
function UIChatView:Layer2_OnClickReturnBtn()
self.chatLayer2:SetActive(false)
self.currChatChannelId = "0"
@ -739,6 +849,7 @@ function UIChatView:EnterChatLayer2(channelId, chatData)
self.chatLayer2:SetActive(true)
self:CloseAllInputToolBarToggles()
self:RefreshTitleBarForChatLayer2(channelId)
self:ResetInputField()
self.currChatData = chatData
local datas = chatData.chats
local max = datas and #datas or 0
@ -843,7 +954,6 @@ function UIChatView:AddUIEventListener()
--uIChatRootWorld:AddUIEventListener()
self.uiBase:AddButtonEventListener(self.btnEmoji1.button, self, self.OnEmojiBgClick)
self.uiBase:AddButtonEventListener(self.BtnClose.button, self, self.OnBtnClose)
self.uiBase:AddToggleEventListener(self.messageTabBtn.toggle, self, self.OnBottomTabChange, BottomTabType.MessageTab)
@ -861,20 +971,21 @@ end
local currInputToolBarToggleType = 0
function UIChatView:OnValueChanged_InputToolBarToggleGroup(toggle, toggleType, isOn)
LogError("toggle: "..tostring(toggleType).."-"..tostring(isOn))
--LogError("toggle: "..tostring(toggleType).."-"..tostring(isOn))
if isOn == false then
self:CloseAllInputToolBarToggles()
return
end
if currInputToolBarToggleType == toggleType then
LogError("UIChatView: close "..tostring(toggleType))
--LogError("UIChatView: close "..tostring(toggleType))
self:CloseAllInputToolBarToggles()
else
LogError("UIChatView: open "..tostring(toggleType))
--LogError("UIChatView: open "..tostring(toggleType))
self:ShowInputToolBarWindow(toggleType)
end
end
local testCount = 1
function UIChatView:ShowInputToolBarWindow(toggleType)
self:CloseAllInputToolBarToggles()
self.InputBarToggles[toggleType].on:SetActive(true)
@ -882,7 +993,18 @@ function UIChatView:ShowInputToolBarWindow(toggleType)
self.InputBarWindows[toggleType]:SetActive(true)
self.chatLayer2.AnyBtn:SetActive(true)
currInputToolBarToggleType = toggleType
if toggleType == CONST_TOGGLE_STORY then
testCount = testCount + 5
local storyDatas = {
{id=10089, txt="好的好的!"..testCount},
{id=20098, txt="不行啊,我有事"..testCount},
{id=20198, txt="让我考虑一下!"..testCount}
}
self:ShowStoryWindow(storyDatas)
end
end
function UIChatView:CloseAllInputToolBarToggles()
for k, v in pairs(self.InputBarToggles) do
v.on:SetActive(false)
@ -921,10 +1043,9 @@ function UIChatView:OnClose()
end
function UIChatView:OnDispose()
self.emojiWindow1:SetActive(false)
self.chatInputField1.inputField:DeactivateInputField()
self.emojiWindow1.loopVerticalScrollRect:ClearCells()
self.chatLayer2.emojiWindow:SetActive(false)
self.chatLayer2.inputField.inputField:DeactivateInputField()
self.chatLayer2.emojiWindow.loopVerticalScrollRect:ClearCells()
end
function UIChatView:IsSomeFrameCount(keyName)

View File

@ -109,39 +109,6 @@
---@field public dateWindow UIChat__Generate_chatLayer2_dateWindow
---@field public photoWindow UIChat__Generate_chatLayer2_photoWindow
---@class UIChat__Generate_btnSendChat1
---@field public gameObject UnityEngine.GameObject
---@field public button UnityEngine.UI.Button
---@class UIChat__Generate_btnEmoji1
---@field public gameObject UnityEngine.GameObject
---@field public button UnityEngine.UI.Button
---@class UIChat__Generate_chatInputField1
---@field public gameObject UnityEngine.GameObject
---@field public inputField UnityEngine.UI.InputField
---@class UIChat__Generate_emojiWindow1
---@field public gameObject UnityEngine.GameObject
---@field public loopVerticalScrollRect UnityEngine.UI.LoopVerticalScrollRect
---@field public content UnityEngine.GameObject
---@class UIChat__Generate_layer1_TitleBarText
---@field public gameObject UnityEngine.GameObject
---@field public text TMPro.TextMeshProUGUI
---@class UIChat__Generate_layer1_TitleBarReturnBtn
---@field public gameObject UnityEngine.GameObject
---@field public button UnityEngine.UI.Button
---@class UIChat__Generate_layer1_ChatContent
---@field public gameObject UnityEngine.GameObject
---@field public verticalLayoutGroup UnityEngine.UI.VerticalLayoutGroup
---@class UIChat__Generate_layer1_ChatContentScrollView
---@field public gameObject UnityEngine.GameObject
---@field public loopVerticalScrollRect UnityEngine.UI.LoopVerticalScrollRect
---@class UIChat__Generate_btnBack
---@field public gameObject UnityEngine.GameObject
---@field public button UnityEngine.UI.Button
@ -212,6 +179,16 @@
---@field public gameObject UnityEngine.GameObject
---@field public button UnityEngine.UI.Button
---@class UIChat__Generate_photoItem
---@field public gameObject UnityEngine.GameObject
---@field public icon UnityEngine.GameObject
---@field public title UnityEngine.GameObject
---@class UIChat__Generate_dateItem
---@field public gameObject UnityEngine.GameObject
---@field public icon UnityEngine.GameObject
---@field public title UnityEngine.GameObject
---@class UIChat__Generate_giftItem
---@field public gameObject UnityEngine.GameObject
---@field public icon UnityEngine.GameObject
@ -326,6 +303,9 @@
---@field private btnBlock UIChat__Generate_btnBlock
---@field private emojiItem UnityEngine.GameObject
---@field private giftItem UIChat__Generate_giftItem
---@field private dateItem UIChat__Generate_dateItem
---@field private photoItem UIChat__Generate_photoItem
---@field private storyItem UnityEngine.GameObject
---@field private BtnClose UIChat__Generate_BtnClose
---@field private chatLayer0 UIChat__Generate_chatLayer0
---@field private chatTab UIChat__Generate_chatTab
@ -335,16 +315,6 @@
---@field private searchTabBtn UIChat__Generate_searchTabBtn
---@field private meTabBtn UIChat__Generate_meTabBtn
---@field private btnBack UIChat__Generate_btnBack
---@field private chatLayer1 UnityEngine.GameObject
---@field private layer1_ChatContentScrollView UIChat__Generate_layer1_ChatContentScrollView
---@field private layer1_ChatContent UIChat__Generate_layer1_ChatContent
---@field private layer1_TitleBarReturnBtn UIChat__Generate_layer1_TitleBarReturnBtn
---@field private layer1_TitleBarText UIChat__Generate_layer1_TitleBarText
---@field private emojiWindow1 UIChat__Generate_emojiWindow1
---@field private input1 UnityEngine.GameObject
---@field private chatInputField1 UIChat__Generate_chatInputField1
---@field private btnEmoji1 UIChat__Generate_btnEmoji1
---@field private btnSendChat1 UIChat__Generate_btnSendChat1
---@field private chatLayer2 UIChat__Generate_chatLayer2
local UIChatView = class("UIChatView", require("UIViewBase"))
@ -450,10 +420,6 @@ function UIChatView:InitGenerate(Root, data)
self:InitGenerate__83(Root,data)
self:InitGenerate__84(Root,data)
self:InitGenerate__85(Root,data)
self:InitGenerate__86(Root,data)
self:InitGenerate__87(Root,data)
self:InitGenerate__88(Root,data)
self:InitGenerate__89(Root,data)
end
@ -818,6 +784,90 @@ end
---@private
function UIChatView:InitGenerate__27(Root, data)
--[[
UIAnimator/Window/DateItem
--]]
local tmp = Root:Find("UIAnimator/Window/DateItem").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.dateItem = tmp
end
---@private
function UIChatView:InitGenerate__28(Root, data)
--[[
UIAnimator/Window/DateItem/Icon
--]]
local tmp = Root:Find("UIAnimator/Window/DateItem/Icon").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.dateItem.icon = tmp
end
---@private
function UIChatView:InitGenerate__29(Root, data)
--[[
UIAnimator/Window/DateItem/Info/Title
--]]
local tmp = Root:Find("UIAnimator/Window/DateItem/Info/Title").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.dateItem.title = tmp
end
---@private
function UIChatView:InitGenerate__30(Root, data)
--[[
UIAnimator/Window/PhotoItem
--]]
local tmp = Root:Find("UIAnimator/Window/PhotoItem").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.photoItem = tmp
end
---@private
function UIChatView:InitGenerate__31(Root, data)
--[[
UIAnimator/Window/PhotoItem/Icon
--]]
local tmp = Root:Find("UIAnimator/Window/PhotoItem/Icon").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.photoItem.icon = tmp
end
---@private
function UIChatView:InitGenerate__32(Root, data)
--[[
UIAnimator/Window/PhotoItem/Info/Title
--]]
local tmp = Root:Find("UIAnimator/Window/PhotoItem/Info/Title").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.photoItem.title = tmp
end
---@private
function UIChatView:InitGenerate__33(Root, data)
--[[
UIAnimator/Window/StoryItem
--]]
local tmp = Root:Find("UIAnimator/Window/StoryItem").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.storyItem = tmp
end
---@private
function UIChatView:InitGenerate__34(Root, data)
--[[
UIAnimator/Window/BtnCloseFlat
--]]
@ -831,7 +881,7 @@ function UIChatView:InitGenerate__27(Root, data)
end
---@private
function UIChatView:InitGenerate__28(Root, data)
function UIChatView:InitGenerate__35(Root, data)
--[[
UIAnimator/Window/ChatLayer0
--]]
@ -843,7 +893,7 @@ function UIChatView:InitGenerate__28(Root, data)
end
---@private
function UIChatView:InitGenerate__29(Root, data)
function UIChatView:InitGenerate__36(Root, data)
--[[
UIAnimator/Window/ChatLayer0/TitleBar/TitleBarText
--]]
@ -857,7 +907,7 @@ function UIChatView:InitGenerate__29(Root, data)
end
---@private
function UIChatView:InitGenerate__30(Root, data)
function UIChatView:InitGenerate__37(Root, data)
--[[
UIAnimator/Window/ChatLayer0/ChatTab
--]]
@ -869,7 +919,7 @@ function UIChatView:InitGenerate__30(Root, data)
end
---@private
function UIChatView:InitGenerate__31(Root, data)
function UIChatView:InitGenerate__38(Root, data)
--[[
UIAnimator/Window/ChatLayer0/ChatTab/ChatTabLoopScrollView
--]]
@ -883,7 +933,7 @@ function UIChatView:InitGenerate__31(Root, data)
end
---@private
function UIChatView:InitGenerate__32(Root, data)
function UIChatView:InitGenerate__39(Root, data)
--[[
UIAnimator/Window/ChatLayer0/ChatTab/ChatTabLoopScrollView/Viewport/ChatTabContent
--]]
@ -899,7 +949,7 @@ function UIChatView:InitGenerate__32(Root, data)
end
---@private
function UIChatView:InitGenerate__33(Root, data)
function UIChatView:InitGenerate__40(Root, data)
--[[
UIAnimator/Window/ChatLayer0/SearchTab
--]]
@ -911,7 +961,7 @@ function UIChatView:InitGenerate__33(Root, data)
end
---@private
function UIChatView:InitGenerate__34(Root, data)
function UIChatView:InitGenerate__41(Root, data)
--[[
UIAnimator/Window/ChatLayer0/SearchTab/ChatTabLoopScrollView
--]]
@ -925,7 +975,7 @@ function UIChatView:InitGenerate__34(Root, data)
end
---@private
function UIChatView:InitGenerate__35(Root, data)
function UIChatView:InitGenerate__42(Root, data)
--[[
UIAnimator/Window/ChatLayer0/SearchTab/ChatTabLoopScrollView/Viewport/ChatTabContent
--]]
@ -941,7 +991,7 @@ function UIChatView:InitGenerate__35(Root, data)
end
---@private
function UIChatView:InitGenerate__36(Root, data)
function UIChatView:InitGenerate__43(Root, data)
--[[
UIAnimator/Window/ChatLayer0/MeTab
--]]
@ -953,7 +1003,7 @@ function UIChatView:InitGenerate__36(Root, data)
end
---@private
function UIChatView:InitGenerate__37(Root, data)
function UIChatView:InitGenerate__44(Root, data)
--[[
UIAnimator/Window/ChatLayer0/MeTab/ChatTabLoopScrollView
--]]
@ -967,7 +1017,7 @@ function UIChatView:InitGenerate__37(Root, data)
end
---@private
function UIChatView:InitGenerate__38(Root, data)
function UIChatView:InitGenerate__45(Root, data)
--[[
UIAnimator/Window/ChatLayer0/MeTab/ChatTabLoopScrollView/Viewport/ChatTabContent
--]]
@ -983,7 +1033,7 @@ function UIChatView:InitGenerate__38(Root, data)
end
---@private
function UIChatView:InitGenerate__39(Root, data)
function UIChatView:InitGenerate__46(Root, data)
--[[
UIAnimator/Window/ChatLayer0/BottomTabBar/MessageTabBtn
--]]
@ -997,7 +1047,7 @@ function UIChatView:InitGenerate__39(Root, data)
end
---@private
function UIChatView:InitGenerate__40(Root, data)
function UIChatView:InitGenerate__47(Root, data)
--[[
UIAnimator/Window/ChatLayer0/BottomTabBar/SearchTabBtn
--]]
@ -1011,7 +1061,7 @@ function UIChatView:InitGenerate__40(Root, data)
end
---@private
function UIChatView:InitGenerate__41(Root, data)
function UIChatView:InitGenerate__48(Root, data)
--[[
UIAnimator/Window/ChatLayer0/BottomTabBar/MeTabBtn
--]]
@ -1025,7 +1075,7 @@ function UIChatView:InitGenerate__41(Root, data)
end
---@private
function UIChatView:InitGenerate__42(Root, data)
function UIChatView:InitGenerate__49(Root, data)
--[[
UIAnimator/Window/BtnBack
--]]
@ -1038,156 +1088,8 @@ function UIChatView:InitGenerate__42(Root, data)
tmp.button = tmp:GetComponent(Enum.TypeInfo.Button)
end
---@private
function UIChatView:InitGenerate__43(Root, data)
--[[
UIAnimator/Window/ChatLayer1
--]]
local tmp = Root:Find("UIAnimator/Window/ChatLayer1").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.chatLayer1 = tmp
end
---@private
function UIChatView:InitGenerate__44(Root, data)
--[[
UIAnimator/Window/ChatLayer1/Layer1_ChatContentScrollView
--]]
local tmp = Root:Find("UIAnimator/Window/ChatLayer1/Layer1_ChatContentScrollView").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.layer1_ChatContentScrollView = tmp
tmp.loopVerticalScrollRect = tmp:GetComponent(Enum.TypeInfo.LoopVerticalScrollRect)
end
---@private
function UIChatView:InitGenerate__45(Root, data)
--[[
UIAnimator/Window/ChatLayer1/Layer1_ChatContentScrollView/Viewport/Layer1_ChatContent
--]]
local tmp = Root:Find("UIAnimator/Window/ChatLayer1/Layer1_ChatContentScrollView/Viewport/Layer1_ChatContent").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.layer1_ChatContent = tmp
tmp.verticalLayoutGroup = tmp:GetComponent(Enum.TypeInfo.VerticalLayoutGroup)
end
---@private
function UIChatView:InitGenerate__46(Root, data)
--[[
UIAnimator/Window/ChatLayer1/Level1_TitleBar/Layer1_TitleBarReturnBtn
--]]
local tmp = Root:Find("UIAnimator/Window/ChatLayer1/Level1_TitleBar/Layer1_TitleBarReturnBtn").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.layer1_TitleBarReturnBtn = tmp
tmp.button = tmp:GetComponent(Enum.TypeInfo.Button)
end
---@private
function UIChatView:InitGenerate__47(Root, data)
--[[
UIAnimator/Window/ChatLayer1/Level1_TitleBar/Layer1_TitleBarText
--]]
local tmp = Root:Find("UIAnimator/Window/ChatLayer1/Level1_TitleBar/Layer1_TitleBarText").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.layer1_TitleBarText = tmp
tmp.text = tmp:GetComponent(Enum.TypeInfo.TextMeshProUGUI)
end
---@private
function UIChatView:InitGenerate__48(Root, data)
--[[
UIAnimator/Window/ChatLayer1/EmojiWindow1
--]]
local tmp = Root:Find("UIAnimator/Window/ChatLayer1/EmojiWindow1").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.emojiWindow1 = tmp
tmp.loopVerticalScrollRect = tmp:GetComponent(Enum.TypeInfo.LoopVerticalScrollRect)
end
---@private
function UIChatView:InitGenerate__49(Root, data)
--[[
UIAnimator/Window/ChatLayer1/EmojiWindow1/Viewport/Content
--]]
local tmp = Root:Find("UIAnimator/Window/ChatLayer1/EmojiWindow1/Viewport/Content").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.emojiWindow1.content = tmp
end
---@private
function UIChatView:InitGenerate__50(Root, data)
--[[
UIAnimator/Window/ChatLayer1/Input1
--]]
local tmp = Root:Find("UIAnimator/Window/ChatLayer1/Input1").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.input1 = tmp
end
---@private
function UIChatView:InitGenerate__51(Root, data)
--[[
UIAnimator/Window/ChatLayer1/Input1/ChatInputField1
--]]
local tmp = Root:Find("UIAnimator/Window/ChatLayer1/Input1/ChatInputField1").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.chatInputField1 = tmp
tmp.inputField = tmp:GetComponent(Enum.TypeInfo.InputField)
end
---@private
function UIChatView:InitGenerate__52(Root, data)
--[[
UIAnimator/Window/ChatLayer1/Input1/BtnEmoji1
--]]
local tmp = Root:Find("UIAnimator/Window/ChatLayer1/Input1/BtnEmoji1").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.btnEmoji1 = tmp
tmp.button = tmp:GetComponent(Enum.TypeInfo.Button)
end
---@private
function UIChatView:InitGenerate__53(Root, data)
--[[
UIAnimator/Window/ChatLayer1/Input1/BtnSendChat1
--]]
local tmp = Root:Find("UIAnimator/Window/ChatLayer1/Input1/BtnSendChat1").gameObject
if tolua.getpeer(tmp) == nil then
tolua.setpeer(tmp, {})
end
self.btnSendChat1 = tmp
tmp.button = tmp:GetComponent(Enum.TypeInfo.Button)
end
---@private
function UIChatView:InitGenerate__54(Root, data)
--[[
UIAnimator/Window/ChatLayer2
--]]
@ -1199,7 +1101,7 @@ function UIChatView:InitGenerate__54(Root, data)
end
---@private
function UIChatView:InitGenerate__55(Root, data)
function UIChatView:InitGenerate__51(Root, data)
--[[
UIAnimator/Window/ChatLayer2/LoopListView
--]]
@ -1215,7 +1117,7 @@ function UIChatView:InitGenerate__55(Root, data)
end
---@private
function UIChatView:InitGenerate__56(Root, data)
function UIChatView:InitGenerate__52(Root, data)
--[[
UIAnimator/Window/ChatLayer2/TitleBar/TitleBarReturnBtn
--]]
@ -1229,7 +1131,7 @@ function UIChatView:InitGenerate__56(Root, data)
end
---@private
function UIChatView:InitGenerate__57(Root, data)
function UIChatView:InitGenerate__53(Root, data)
--[[
UIAnimator/Window/ChatLayer2/TitleBar/TitleBarText
--]]
@ -1243,7 +1145,7 @@ function UIChatView:InitGenerate__57(Root, data)
end
---@private
function UIChatView:InitGenerate__58(Root, data)
function UIChatView:InitGenerate__54(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputTextBar
--]]
@ -1255,7 +1157,7 @@ function UIChatView:InitGenerate__58(Root, data)
end
---@private
function UIChatView:InitGenerate__59(Root, data)
function UIChatView:InitGenerate__55(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputTextBar/InputField
--]]
@ -1269,7 +1171,7 @@ function UIChatView:InitGenerate__59(Root, data)
end
---@private
function UIChatView:InitGenerate__60(Root, data)
function UIChatView:InitGenerate__56(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputTextBar/BtnEmoji
--]]
@ -1283,7 +1185,7 @@ function UIChatView:InitGenerate__60(Root, data)
end
---@private
function UIChatView:InitGenerate__61(Root, data)
function UIChatView:InitGenerate__57(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputTextBar/BtnSend
--]]
@ -1297,7 +1199,7 @@ function UIChatView:InitGenerate__61(Root, data)
end
---@private
function UIChatView:InitGenerate__62(Root, data)
function UIChatView:InitGenerate__58(Root, data)
--[[
UIAnimator/Window/ChatLayer2/Alpha
--]]
@ -1311,7 +1213,7 @@ function UIChatView:InitGenerate__62(Root, data)
end
---@private
function UIChatView:InitGenerate__63(Root, data)
function UIChatView:InitGenerate__59(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputToolBar
--]]
@ -1323,7 +1225,7 @@ function UIChatView:InitGenerate__63(Root, data)
end
---@private
function UIChatView:InitGenerate__64(Root, data)
function UIChatView:InitGenerate__60(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputToolBar/InputToolBarToggleGroup
--]]
@ -1337,7 +1239,7 @@ function UIChatView:InitGenerate__64(Root, data)
end
---@private
function UIChatView:InitGenerate__65(Root, data)
function UIChatView:InitGenerate__61(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputToolBar/InputToolBarToggleGroup/EmojiToggle
--]]
@ -1351,7 +1253,7 @@ function UIChatView:InitGenerate__65(Root, data)
end
---@private
function UIChatView:InitGenerate__66(Root, data)
function UIChatView:InitGenerate__62(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputToolBar/InputToolBarToggleGroup/EmojiToggle/On
--]]
@ -1363,7 +1265,7 @@ function UIChatView:InitGenerate__66(Root, data)
end
---@private
function UIChatView:InitGenerate__67(Root, data)
function UIChatView:InitGenerate__63(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputToolBar/InputToolBarToggleGroup/EmojiToggle/Off
--]]
@ -1375,7 +1277,7 @@ function UIChatView:InitGenerate__67(Root, data)
end
---@private
function UIChatView:InitGenerate__68(Root, data)
function UIChatView:InitGenerate__64(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputToolBar/InputToolBarToggleGroup/GiftToggle
--]]
@ -1389,7 +1291,7 @@ function UIChatView:InitGenerate__68(Root, data)
end
---@private
function UIChatView:InitGenerate__69(Root, data)
function UIChatView:InitGenerate__65(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputToolBar/InputToolBarToggleGroup/GiftToggle/On
--]]
@ -1401,7 +1303,7 @@ function UIChatView:InitGenerate__69(Root, data)
end
---@private
function UIChatView:InitGenerate__70(Root, data)
function UIChatView:InitGenerate__66(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputToolBar/InputToolBarToggleGroup/GiftToggle/Off
--]]
@ -1413,7 +1315,7 @@ function UIChatView:InitGenerate__70(Root, data)
end
---@private
function UIChatView:InitGenerate__71(Root, data)
function UIChatView:InitGenerate__67(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputToolBar/InputToolBarToggleGroup/StoryToggle
--]]
@ -1427,7 +1329,7 @@ function UIChatView:InitGenerate__71(Root, data)
end
---@private
function UIChatView:InitGenerate__72(Root, data)
function UIChatView:InitGenerate__68(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputToolBar/InputToolBarToggleGroup/StoryToggle/On
--]]
@ -1439,7 +1341,7 @@ function UIChatView:InitGenerate__72(Root, data)
end
---@private
function UIChatView:InitGenerate__73(Root, data)
function UIChatView:InitGenerate__69(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputToolBar/InputToolBarToggleGroup/StoryToggle/Off
--]]
@ -1451,7 +1353,7 @@ function UIChatView:InitGenerate__73(Root, data)
end
---@private
function UIChatView:InitGenerate__74(Root, data)
function UIChatView:InitGenerate__70(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputToolBar/InputToolBarToggleGroup/DateToggle
--]]
@ -1465,7 +1367,7 @@ function UIChatView:InitGenerate__74(Root, data)
end
---@private
function UIChatView:InitGenerate__75(Root, data)
function UIChatView:InitGenerate__71(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputToolBar/InputToolBarToggleGroup/DateToggle/On
--]]
@ -1477,7 +1379,7 @@ function UIChatView:InitGenerate__75(Root, data)
end
---@private
function UIChatView:InitGenerate__76(Root, data)
function UIChatView:InitGenerate__72(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputToolBar/InputToolBarToggleGroup/DateToggle/Off
--]]
@ -1489,7 +1391,7 @@ function UIChatView:InitGenerate__76(Root, data)
end
---@private
function UIChatView:InitGenerate__77(Root, data)
function UIChatView:InitGenerate__73(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputToolBar/InputToolBarToggleGroup/PhotoToggle
--]]
@ -1503,7 +1405,7 @@ function UIChatView:InitGenerate__77(Root, data)
end
---@private
function UIChatView:InitGenerate__78(Root, data)
function UIChatView:InitGenerate__74(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputToolBar/InputToolBarToggleGroup/PhotoToggle/On
--]]
@ -1515,7 +1417,7 @@ function UIChatView:InitGenerate__78(Root, data)
end
---@private
function UIChatView:InitGenerate__79(Root, data)
function UIChatView:InitGenerate__75(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputToolBar/InputToolBarToggleGroup/PhotoToggle/Off
--]]
@ -1527,7 +1429,7 @@ function UIChatView:InitGenerate__79(Root, data)
end
---@private
function UIChatView:InitGenerate__80(Root, data)
function UIChatView:InitGenerate__76(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputToolBar/EmojiWindow
--]]
@ -1541,7 +1443,7 @@ function UIChatView:InitGenerate__80(Root, data)
end
---@private
function UIChatView:InitGenerate__81(Root, data)
function UIChatView:InitGenerate__77(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputToolBar/EmojiWindow/Viewport/Content
--]]
@ -1553,7 +1455,7 @@ function UIChatView:InitGenerate__81(Root, data)
end
---@private
function UIChatView:InitGenerate__82(Root, data)
function UIChatView:InitGenerate__78(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputToolBar/GiftWindow
--]]
@ -1567,7 +1469,7 @@ function UIChatView:InitGenerate__82(Root, data)
end
---@private
function UIChatView:InitGenerate__83(Root, data)
function UIChatView:InitGenerate__79(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputToolBar/GiftWindow/Viewport/Content
--]]
@ -1579,7 +1481,7 @@ function UIChatView:InitGenerate__83(Root, data)
end
---@private
function UIChatView:InitGenerate__84(Root, data)
function UIChatView:InitGenerate__80(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputToolBar/StoryWindow
--]]
@ -1593,7 +1495,7 @@ function UIChatView:InitGenerate__84(Root, data)
end
---@private
function UIChatView:InitGenerate__85(Root, data)
function UIChatView:InitGenerate__81(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputToolBar/StoryWindow/Viewport/Content
--]]
@ -1605,7 +1507,7 @@ function UIChatView:InitGenerate__85(Root, data)
end
---@private
function UIChatView:InitGenerate__86(Root, data)
function UIChatView:InitGenerate__82(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputToolBar/DateWindow
--]]
@ -1619,7 +1521,7 @@ function UIChatView:InitGenerate__86(Root, data)
end
---@private
function UIChatView:InitGenerate__87(Root, data)
function UIChatView:InitGenerate__83(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputToolBar/DateWindow/Viewport/Content
--]]
@ -1631,7 +1533,7 @@ function UIChatView:InitGenerate__87(Root, data)
end
---@private
function UIChatView:InitGenerate__88(Root, data)
function UIChatView:InitGenerate__84(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputToolBar/PhotoWindow
--]]
@ -1645,7 +1547,7 @@ function UIChatView:InitGenerate__88(Root, data)
end
---@private
function UIChatView:InitGenerate__89(Root, data)
function UIChatView:InitGenerate__85(Root, data)
--[[
UIAnimator/Window/ChatLayer2/InputToolBar/PhotoWindow/Viewport/Content
--]]
@ -1763,9 +1665,6 @@ function UIChatView:GenerateDestroy()
if tolua.getpeer(self.chatLayer2.loopListView) ~= nil then
tolua.setpeer(self.chatLayer2.loopListView, nil)
end
if tolua.getpeer(self.emojiWindow1.content) ~= nil then
tolua.setpeer(self.emojiWindow1.content, nil)
end
if tolua.getpeer(self.meTab.chatTabContent) ~= nil then
tolua.setpeer(self.meTab.chatTabContent, nil)
end
@ -1787,6 +1686,18 @@ function UIChatView:GenerateDestroy()
if tolua.getpeer(self.chatLayer0.titleBarText) ~= nil then
tolua.setpeer(self.chatLayer0.titleBarText, nil)
end
if tolua.getpeer(self.photoItem.title) ~= nil then
tolua.setpeer(self.photoItem.title, nil)
end
if tolua.getpeer(self.photoItem.icon) ~= nil then
tolua.setpeer(self.photoItem.icon, nil)
end
if tolua.getpeer(self.dateItem.title) ~= nil then
tolua.setpeer(self.dateItem.title, nil)
end
if tolua.getpeer(self.dateItem.icon) ~= nil then
tolua.setpeer(self.dateItem.icon, nil)
end
if tolua.getpeer(self.giftItem.title) ~= nil then
tolua.setpeer(self.giftItem.title, nil)
end
@ -1889,6 +1800,18 @@ function UIChatView:GenerateDestroy()
tolua.setpeer(self.giftItem, nil)
end
self.giftItem = nil
if tolua.getpeer(self.dateItem) ~= nil then
tolua.setpeer(self.dateItem, nil)
end
self.dateItem = nil
if tolua.getpeer(self.photoItem) ~= nil then
tolua.setpeer(self.photoItem, nil)
end
self.photoItem = nil
if tolua.getpeer(self.storyItem) ~= nil then
tolua.setpeer(self.storyItem, nil)
end
self.storyItem = nil
if tolua.getpeer(self.BtnClose) ~= nil then
tolua.setpeer(self.BtnClose, nil)
end
@ -1925,46 +1848,6 @@ function UIChatView:GenerateDestroy()
tolua.setpeer(self.btnBack, nil)
end
self.btnBack = nil
if tolua.getpeer(self.chatLayer1) ~= nil then
tolua.setpeer(self.chatLayer1, nil)
end
self.chatLayer1 = nil
if tolua.getpeer(self.layer1_ChatContentScrollView) ~= nil then
tolua.setpeer(self.layer1_ChatContentScrollView, nil)
end
self.layer1_ChatContentScrollView = nil
if tolua.getpeer(self.layer1_ChatContent) ~= nil then
tolua.setpeer(self.layer1_ChatContent, nil)
end
self.layer1_ChatContent = nil
if tolua.getpeer(self.layer1_TitleBarReturnBtn) ~= nil then
tolua.setpeer(self.layer1_TitleBarReturnBtn, nil)
end
self.layer1_TitleBarReturnBtn = nil
if tolua.getpeer(self.layer1_TitleBarText) ~= nil then
tolua.setpeer(self.layer1_TitleBarText, nil)
end
self.layer1_TitleBarText = nil
if tolua.getpeer(self.emojiWindow1) ~= nil then
tolua.setpeer(self.emojiWindow1, nil)
end
self.emojiWindow1 = nil
if tolua.getpeer(self.input1) ~= nil then
tolua.setpeer(self.input1, nil)
end
self.input1 = nil
if tolua.getpeer(self.chatInputField1) ~= nil then
tolua.setpeer(self.chatInputField1, nil)
end
self.chatInputField1 = nil
if tolua.getpeer(self.btnEmoji1) ~= nil then
tolua.setpeer(self.btnEmoji1, nil)
end
self.btnEmoji1 = nil
if tolua.getpeer(self.btnSendChat1) ~= nil then
tolua.setpeer(self.btnSendChat1, nil)
end
self.btnSendChat1 = nil
if tolua.getpeer(self.chatLayer2) ~= nil then
tolua.setpeer(self.chatLayer2, nil)
end

View File

@ -1,4 +1,4 @@
using System;
using System;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;