public static void Show(ResSymbolInfo symbolInfo, RES_SHOPBUY_COINTYPE coinType, float discount, CSymbolBuyPickDialog.OnConfirmBuyDelegate onClose, CSymbolBuyPickDialog.OnConfirmBuyCommonDelegate onConfirmCommon = null, CUIEvent uieventPars = null)
 {
     if (CSymbolBuyPickDialog.s_theDlg == null)
     {
         CSymbolBuyPickDialog.s_theDlg = new CSymbolBuyPickDialog(symbolInfo, coinType, discount, onClose, onConfirmCommon, uieventPars);
         if (CSymbolBuyPickDialog.s_theDlg._root == null)
         {
             CSymbolBuyPickDialog.s_theDlg = null;
         }
     }
 }
        private void OnClose(bool isOk)
        {
            if (isOk && this._onConfirm != null)
            {
                this._onConfirm(this._callContext, this._count, false, this._uieventPars);
            }
            else if (isOk && this._onConfirmdCommon != null)
            {
                this._onConfirmdCommon(this._uieventPars, this._count);
            }
            Singleton <CUIManager> .GetInstance().CloseForm(CSymbolBuyPickDialog.s_Form_Path);

            CSymbolBuyPickDialog.s_theDlg = null;
        }
        private void OnCloseForm(CUIEvent uiEvent)
        {
            Singleton <CUIEventManager> .GetInstance().RemoveUIEventListener(enUIEventID.BuyPick_Add, new CUIEventManager.OnUIEventHandler(this.OnClickAdd));

            Singleton <CUIEventManager> .GetInstance().RemoveUIEventListener(enUIEventID.BuyPick_Dec, new CUIEventManager.OnUIEventHandler(this.OnClickDec));

            Singleton <CUIEventManager> .GetInstance().RemoveUIEventListener(enUIEventID.BuyPick_Max, new CUIEventManager.OnUIEventHandler(this.OnClickMax));

            Singleton <CUIEventManager> .GetInstance().RemoveUIEventListener(enUIEventID.BuyPick_Confirm, new CUIEventManager.OnUIEventHandler(this.OnClickConfirm));

            Singleton <CUIEventManager> .GetInstance().RemoveUIEventListener(enUIEventID.BuyPick_Cancel, new CUIEventManager.OnUIEventHandler(this.OnClickCancel));

            Singleton <CUIEventManager> .GetInstance().RemoveUIEventListener(enUIEventID.BuyPick_ConfirmFactoryShopBuy, new CUIEventManager.OnUIEventHandler(this.OnConfirmFactoryShopBuy));

            CSymbolBuyPickDialog.s_theDlg = null;
        }