Ejemplo n.º 1
0
    private void RefreshBuyNode()
    {
        buyNode.SafeSetActive(growthFund.TotalBuyTimes() == 0);

        if (growthFund.TotalBuyTimes() > 0)
        {
            defaultDataSource?.Clear();
            var list = new List <PGrowthFund>(moduleCharge.GetGrowthFund());
            list.Sort(SortHandle);
            dataSource = new DataSource <PGrowthFund>(list, scorllView, OnSetData);
        }
        else
        {
            dataSource?.Clear();
            defaultDataSource = new DataSource <string>(ConfigManager.Get <ConfigText>(603).text, defaultScrollView,
                                                        OnDefaultSetData);
        }
    }
Ejemplo n.º 2
0
 public void RefreshCount()
 {
     gotNode.SafeSetActive((Data.info.cycleTotalBuyLimit > 0 && Data.DailyBuyTimes() >= Data.info.cycleTotalBuyLimit) ||
                           (Data.info.allTotalBuyLimit > 0 && Data.TotalBuyTimes() >= Data.info.allTotalBuyLimit));
     costNumber.SafeSetActive(!gotNode.gameObject.activeSelf);
 }
Ejemplo n.º 3
0
    private void SetBtnState()
    {
        bool buy = (m_chargeItem.DailyBuyTimes() < m_chargeItem.info.cycleTotalBuyLimit && m_chargeItem.TotalBuyTimes() < m_chargeItem.info.allTotalBuyLimit);

        m_buyBtn.interactable = buy;
        if (buy)
        {
            Util.SetText(m_buyTxt, 246, 35);
        }
        else
        {
            Util.SetText(m_buyTxt, 246, 36);
        }
    }