【碎片自选箱】通过道具详情跳转别的地方,返回后选中标识居中
parent
eb7d89578a
commit
df76a49401
|
@ -103,6 +103,16 @@ function RewardBoxPanel:OnOpen(...)
|
|||
this.scroll.gameObject:GetComponent("RectTransform").anchoredPosition = #this.rewardGroup ~= 1 and Vector2.New(0, 376) or Vector2.New(0, 444)
|
||||
this.ScrollView.gameObject:GetComponent("RectTransform").sizeDelta = #this.rewardGroup ~= 1 and Vector2.New(940, 830) or Vector2.New(940, 900)
|
||||
|
||||
end
|
||||
|
||||
-- 打开,重新打开时回调
|
||||
function RewardBoxPanel:OnShow()
|
||||
this.name.text = GetLanguageStrById(itemConfig[this.itemId].Name)
|
||||
itemList={}
|
||||
curId = nil
|
||||
tagNum = 1
|
||||
|
||||
--刷新按钮亮光
|
||||
this.selectList ={}
|
||||
for n = 1, this.selectBar.transform.childCount-1 do--设置当前页签
|
||||
table.insert(this.selectList,this.selectBar.transform:GetChild(n).gameObject)
|
||||
|
@ -121,14 +131,6 @@ function RewardBoxPanel:OnOpen(...)
|
|||
end)
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
-- 打开,重新打开时回调
|
||||
function RewardBoxPanel:OnShow()
|
||||
this.name.text = GetLanguageStrById(itemConfig[this.itemId].Name)
|
||||
itemList={}
|
||||
curId = nil
|
||||
tagNum = 1
|
||||
self:RefreshData()
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in New Issue