public override void SetComponent() { this.m_OkDelegate = null; this.m_dtInBox = (base.GetControl("DT_InBox") as DrawTexture); this.m_lbTitle = (base.GetControl("LB_Title") as Label); this.m_lbNotExistButtonNoti = (base.GetControl("LB_Notice") as Label); this.m_btClose = (base.GetControl("Btn_Close") as Button); Button expr_65 = this.m_btClose; expr_65.Click = (EZValueChangedDelegate)Delegate.Combine(expr_65.Click, new EZValueChangedDelegate(this.OnClickClose)); this.m_btOk = (base.GetControl("Button_Ok") as Button); Button expr_A2 = this.m_btOk; expr_A2.Click = (EZValueChangedDelegate)Delegate.Combine(expr_A2.Click, new EZValueChangedDelegate(this.OnClickOk)); for (int i = 0; i < 2; i++) { this.m_dtItemSlot_2[i] = (base.GetControl(string.Format("DT_ItemSlot2_{0}", i + 1)) as DrawTexture); this.m_itItemImg_2[i] = (base.GetControl(string.Format("IT_ItemImg2_{0}", i + 1)) as ItemTexture); this.m_btItem_2[i] = (base.GetControl(string.Format("Btn_ItemInfo2_{0}", i + 1)) as Button); } for (int j = 0; j < 3; j++) { this.m_dtItemSlot_3[j] = (base.GetControl(string.Format("DT_ItemSlot3_{0}", j + 1)) as DrawTexture); this.m_itItemImg_3[j] = (base.GetControl(string.Format("IT_ItemImg3_{0}", j + 1)) as ItemTexture); this.m_btItem_3[j] = (base.GetControl(string.Format("Btn_ItemInfo3_{0}", j + 1)) as Button); } }
public void SetMsg(YesDelegate a_deYes, object a_oObject, NoDelegate b_deNo, object b_oObject, string title, string message, string checkbox1Text, CheckBox1Delegate a_deCheck1, string checkbox2Text, CheckBox2Delegate a_deCheck2, eMsgType type) { if (a_deYes != null) { this.m_YesDelegate = (YesDelegate)Delegate.Combine(this.m_YesDelegate, new YesDelegate(a_deYes.Invoke)); } if (a_oObject != null) { this.m_oYesObject = a_oObject; } if (b_deNo != null) { this.m_NoDelegate = (NoDelegate)Delegate.Combine(this.m_NoDelegate, new NoDelegate(b_deNo.Invoke)); } if (b_oObject != null) { this.m_oNoObject = b_oObject; } this.SetMsgType(type); this.m_LbTitle.Text = title; this.m_LbNote.SetText(message); this.m_LbCheckBox1.SetText(checkbox1Text); if (a_deCheck1 != null) { this.m_Check1Delegate = (CheckBox1Delegate)Delegate.Combine(this.m_Check1Delegate, new CheckBox1Delegate(a_deCheck1.Invoke)); } this.m_LbCheckBox2.SetText(checkbox2Text); if (a_deCheck2 != null) { this.m_Check2Delegate = (CheckBox2Delegate)Delegate.Combine(this.m_Check2Delegate, new CheckBox2Delegate(a_deCheck2.Invoke)); } this.Show(); }
public override void InitializeComponent() { this.m_YesDelegate = null; this.m_oYesObject = null; this.m_NoDelegate = null; this.m_oNoObject = null; UIBaseFileManager instance = NrTSingleton <UIBaseFileManager> .Instance; Form form = this; base.Scale = true; instance.LoadFileAll(ref form, "Message/DLG_MsgBox", G_ID.MSGBOX_DLG, true); }
public void SetMsg(YesDelegate a_deYes, object a_oObject, string title, string message, eMsgType type) { if (a_deYes != null) { this.m_YesDelegate = (YesDelegate)Delegate.Combine(this.m_YesDelegate, new YesDelegate(a_deYes.Invoke)); } if (a_oObject != null) { this.m_oYesObject = a_oObject; } this.SetMsgType(type); this.m_LbTitle.Text = title; this.m_LbNote.SetText(message); this.Show(); }
public void SetMsg(YesDelegate a_deOk, object a_oObject, bool bShowButton, string strTitle, string strNotButtonNotify) { if (a_deOk != null) { this.m_OkDelegate = (YesDelegate)Delegate.Combine(this.m_OkDelegate, new YesDelegate(a_deOk.Invoke)); } if (a_oObject != null) { this.m_oOkObject = a_oObject; } this.m_lbNotExistButtonNoti.SetText(strNotButtonNotify); this.m_lbTitle.Text = strTitle; this.m_lbNotExistButtonNoti.SetText(strNotButtonNotify); this.m_btOk.Hide(!bShowButton); this.m_lbNotExistButtonNoti.Hide(bShowButton); this.Show(); }
public void ShowMsgBox(YesDelegate yesDelegate, object data, string title, string message) { this._yesDelegate = (YesDelegate)Delegate.Combine(this._yesDelegate, yesDelegate); this._data = data; this._lbTitle.Text = title; this._lbNote.Text = message; CharCostumeInfo_Data charCostumeInfo_Data = (CharCostumeInfo_Data)data; if (charCostumeInfo_Data == null) { return; } this._lbSoulGem.Text = string.Format("{0:##,##0}", charCostumeInfo_Data.m_Price1Num); this._lbMythExlixir.Text = string.Format("{0:##,##0}", charCostumeInfo_Data.m_Price2Num); this.VisibleCostumeChar(false); this.Show(); }
public bool PreProcess(ITEM item, int index, YesDelegate a_deYes) { if (item == null) { Debug.LogError("ERROR, Item_Box_Select_Dlg.cs, PreProcess_BoxOpen(), item Is Null"); return(false); } ITEMINFO itemInfo = NrTSingleton <ItemManager> .Instance.GetItemInfo(item.m_nItemUnique); if (itemInfo == null) { return(false); } if (itemInfo.m_nBoxItemUnique.Length <= index) { Debug.LogError("ERROR, Item_Box_Select_Dlg.cs, PreProcess_BoxOpen(), index out of range"); return(false); } return(this.CostumeBoxPreProcess(item, index, a_deYes)); }
public void ShowMessageBox_NotEnough_SolNumBatch(YesDelegate a_deYes, int nCurrentSolArray, int nTotalSolArray) { string textFromMessageBox = NrTSingleton <NrTextMgr> .Instance.GetTextFromMessageBox("94"); string textFromMessageBox2 = NrTSingleton <NrTextMgr> .Instance.GetTextFromMessageBox("147"); string empty = string.Empty; NrTSingleton <CTextParser> .Instance.ReplaceParam(ref empty, new object[] { textFromMessageBox2, "currentnum", nCurrentSolArray, "maxnum", nTotalSolArray }); MsgBoxUI msgBoxUI = NrTSingleton <FormsManager> .Instance.LoadForm(G_ID.MSGBOX_DLG) as MsgBoxUI; msgBoxUI.SetMsg(a_deYes, null, textFromMessageBox, empty, eMsgType.MB_OK_CANCEL, 2); }
private bool CostumeBoxPreProcess(ITEM item, int index, YesDelegate a_deYes) { ITEMINFO itemInfo = NrTSingleton <ItemManager> .Instance.GetItemInfo(item.m_nItemUnique); if (!itemInfo.IsItemATB(33554432L)) { return(false); } int itemunique = itemInfo.m_nBoxItemUnique[index]; ITEMINFO itemInfo2 = NrTSingleton <ItemManager> .Instance.GetItemInfo(itemunique); if (itemInfo2 == null) { return(false); } if (itemInfo2.m_nFunctions != 14) { return(false); } int num = itemInfo2.m_nParam[0]; int costumeSolKind = NrTSingleton <NrCharCostumeTableManager> .Instance.GetCostumeSolKind(num); string textFromInterface = NrTSingleton <NrTextMgr> .Instance.GetTextFromInterface("845"); if (!NrTSingleton <NkCharManager> .Instance.m_kMyCharInfo.IsMySolKindExist(costumeSolKind)) { NrTSingleton <FormsManager> .Instance.ShowMessageBox(textFromInterface, NrTSingleton <NrTextMgr> .Instance.GetTextFromMessageBox("355"), eMsgType.MB_OK_CANCEL, a_deYes, index); return(true); } if (NrTSingleton <NrCharCostumeTableManager> .Instance.IsBuyCostume(num)) { NrTSingleton <FormsManager> .Instance.ShowMessageBox(textFromInterface, NrTSingleton <NrTextMgr> .Instance.GetTextFromMessageBox("356"), eMsgType.MB_OK_CANCEL, a_deYes, index); return(true); } return(false); }
public void ShowMessageBox(string strTitle, string strMessage, eMsgType eMessageType, YesDelegate a_deYes = null, object obj = null) { MsgHandler.Handle("SetMsgBox", new object[] { a_deYes, obj, strTitle, strMessage, eMessageType }); }