public void PlayHide(GUIDialogBase dialogBase) { if (showSequence != null) { showSequence.Kill(); } if (guiControlLocation != null) { hideSequence = DOTween.Sequence(); SettingHideEffect(); hideSequence.AppendCallback(() => { OnEndHide(); GUIManager.InvokeEvent(dialogName, DialogEvent.Hidden); dialogBase.DestroyDialog(this); }); hideSequence.Play(); showStatus = DialogStatus.Hiding; } else { showStatus = DialogStatus.Hiding; OnEndHide(); GUIManager.InvokeEvent(dialogName, DialogEvent.Hidden); dialogBase.DestroyDialog(this); } }
public void AddRectChecker(DialogName dialogName, RectTransform rect) { GUIDialogBase foundDlg = listDialogs.Find(dlg => dlg.DialogName == dialogName); if (foundDlg != null) { foundDlg.rectCheckers.Add(rect); } }
public void UpdateDialogData(DialogName dlgName, string instanceId, object param = null) { GUIDialogBase foundDlg = listDialogs.Find(dlg => dlg.DialogName == dlgName); if (foundDlg == null) { Debug.LogError("Can not find dialog:" + dlgName.ToString()); return; } foundDlg.UpdateData(instanceId, param); }
public void HideDialog(DialogName dlgName, string instanceId, object param = null, bool forceImediate = false) { GUIDialogBase foundDlg = listDialogs.Find(dlg => dlg.DialogName == dlgName); if (foundDlg == null) { Debug.LogError("Can not find dialog:" + dlgName.ToString()); return; } foundDlg.Hide(param, instanceId, forceImediate); }
public void ShowDialog(DialogName dlgName, bool closeOnClickBlackBorder = false, object param = null) { if (!CanShow(dlgName)) { return; } GUIDialogBase foundDlg = listDialogs.Find(dlg => dlg.DialogName == dlgName); if (foundDlg == null) { return; } foundDlg.TryShow(param, closeOnClickBlackBorder); }