Ejemplo n.º 1
0
    public void Construct(PopupManager popupManager,
                          TradableAssetManager tradableAssetManager,
                          TradableAssetButtonManager tradableAssetButtonManager,
                          TradableAssetImageManager tradableAssetImageManager,
                          EthereumTransactionButtonManager transactionButtonManager,
                          TradableAssetNotificationManager notificationManager)
    {
        this.popupManager               = popupManager;
        this.tradableAssetManager       = tradableAssetManager;
        this.tradableAssetButtonManager = tradableAssetButtonManager;
        this.tradableAssetImageManager  = tradableAssetImageManager;
        this.transactionButtonManager   = transactionButtonManager;
        this.notificationManager        = notificationManager;

        notificationManager.OnNotificationsUpdated += UpdateAssetNotifications;
    }
    public TradableAssetPriceManager(
        CoinMarketCapDataManager coinMarketCapDataManager,
        DubiExDataManager dubiexDataManager,
        CurrencyManager currencyManager,
        TradableAssetManager tradableAssetManager,
        TradableAssetButtonManager tradableAssetButtonManager,
        PeriodicUpdateManager periodicUpdateManager)
    {
        this.coinMarketCapDataManager = coinMarketCapDataManager;
        this.dubiexDataManager        = dubiexDataManager;
        this.tradableAssetManager     = tradableAssetManager;

        tradableAssetButtonManager.OnActiveButtonChanged += activeButton => UpdatePrice(activeButton.ButtonInfo);
        currencyManager.OnCurrencyChanged += ClearPrices;

        UserWalletManager.OnWalletLoadSuccessful += () => periodicUpdateManager.AddPeriodicUpdater(this);
    }
Ejemplo n.º 3
0
    public void Construct(
        UserWalletManager userWalletManager,
        EthereumTransactionManager ethereumTransactionManager,
        EthereumTransactionButtonManager ethereumTransactionButtonManager,
        TradableAssetManager tradableAssetManager,
        TradableAssetButtonManager tradableAssetButtonManager,
        TradableAssetNotificationManager tradableAssetNotificationManager,
        LockedPRPSManager lockedPRPSManager,
        LockPRPSManager lockPRPSManager)
    {
        this.userWalletManager                = userWalletManager;
        this.ethereumTransactionManager       = ethereumTransactionManager;
        this.ethereumTransactionButtonManager = ethereumTransactionButtonManager;
        this.tradableAssetManager             = tradableAssetManager;
        this.tradableAssetButtonManager       = tradableAssetButtonManager;
        this.tradableAssetNotificationManager = tradableAssetNotificationManager;
        this.lockedPRPSManager                = lockedPRPSManager;
        this.lockPRPSManager = lockPRPSManager;

        bool showTooltips = SecurePlayerPrefs.GetBool(PlayerPrefConstants.SETTING_SHOW_TOOLTIPS);

        foreach (TooltipItem tooltip in tooltipItems)
        {
            if (showTooltips)
            {
                tooltip.PopupManager = popupManager;
            }
            else if (tooltip.infoIcon)
            {
                tooltip.gameObject.SetActive(false);
            }
            else
            {
                tooltip.enabled = false;
            }
        }
    }
Ejemplo n.º 4
0
 public ButtonAnimator(TradableAssetButtonManager tradableAssetButtonManager)
 {
     tradableAssetButtonManager.OnTradableAssetButtonCreated += asset => AnimateButtonIn(asset.transform.parent.gameObject);
     tradableAssetButtonManager.OnTradableAssetButtonRemoved += asset => AnimateButtonOut(asset.transform.parent.gameObject);
 }