From 7674f5aee893b74cc0d616b9c40467c8846f243c Mon Sep 17 00:00:00 2001 From: hch <305670599@qq.com> Date: 星期二, 05 八月 2025 20:59:25 +0800 Subject: [PATCH] 122 子 【武将】武将系统 - 武将列表界面 --- Main/System/HeroUI/HeroPosWin.cs | 26 ++++++++++++++++---------- 1 files changed, 16 insertions(+), 10 deletions(-) diff --git a/Main/System/HeroUI/HeroPosWin.cs b/Main/System/HeroUI/HeroPosWin.cs index 0cbf08c..5689a2c 100644 --- a/Main/System/HeroUI/HeroPosWin.cs +++ b/Main/System/HeroUI/HeroPosWin.cs @@ -136,16 +136,7 @@ RefreshFlyHead(); RefreshConn(); - if (HeroManager.Instance.GetHeroCount() == 0) - { - heroListEmpty.SetActive(true); - heroListScroller.SetActive(false); - } - else - { - heroListEmpty.SetActive(false); - heroListScroller.SetActive(true); - } + RefreshEmptyTip(); showConnTipToggleBtn.isOn = isToggleOn; @@ -181,6 +172,21 @@ HeroUIManager.Instance.selectTeamPosCountry = country; HeroUIManager.Instance.SortHeroOnTeamList(); CreateScroller(); + RefreshEmptyTip(); + } + + void RefreshEmptyTip() + { + if (HeroUIManager.Instance.heroOnTeamSortList.Count <= 0) + { + heroListEmpty.SetActive(true); + heroListScroller.SetActive(false); + } + else + { + heroListEmpty.SetActive(false); + heroListScroller.SetActive(true); + } } void OnRefreshCell(ScrollerDataType type, CellView cell) -- Gitblit v1.8.0