public void Setup(Project project) { if (_project == null || _project.ObjectId != project.ObjectId) { ExpenseList.ClearElements(); _project = project; Name.text = project.Name; Description.text = project.Description; if (_project.SubmittedUsers.Contains(User.CurrentParseUser.ObjectId)) { SubmitText.text = OPEN; } else { SubmitText.text = SUBMIT; } StartCoroutine(ProcessExpenses()); } if (_project.ProjectLeader.ObjectId == User.CurrentParseUser.ObjectId) { AddUserButton.Present(); } }
public void Present(string title, string message, string inputPlaceholder, System.Action <string> confirmCallback, System.Action cancelCallback, bool showClose = false) { confirm = confirmCallback; cancel = cancelCallback; InputField.PlaceholderText = inputPlaceholder; InputField.Text = ""; if (showClose) { CloseButton.Present(); } TitleText.text = title; MessageText.text = message; UIAlertController.Instance.PresentAlert(this);//Open(); }
protected override void OnPresent(UIView view) { if (CurrentView && CurrentView.name == view.name) { return; } base.OnPresent(view); if ((_viewStack != null && BackButton != null)) { if (_viewStack.Count == 1) { BackButton.Present(); } } _viewStack.Push(view); CurrentView = view; }
public void OpenNext() { AlertContent content = _alertQueue.Peek(); confirm = content.Confirm; cancel = content.Cancel; if (content.ShowClose) { CloseButton.Present(); } else { CloseButton.Remove(); } TitleText.text = content.Title; MessageText.text = content.Message; ConfirmText.text = content.ConfirmText; UIAlertController.Instance.PresentAlert(this);//Open(); }