private void Confirm()
        {
            if (selectedType != null && feedbackDescription != "")
            {
                Feedback feedback = new Feedback(_feedbackController.GenerateId(), Username, SelectedType, FeedbackDescription);
                _feedbackController.Add(feedback);

                /*SelectedType = null;
                 * FeedbackDescription = "";*/
                parent.Close();
            }
        }
示例#2
0
 //Updates UserFeedback and closes window
 private void FeedbackClick(object param)
 {
     int.TryParse(param.ToString(), out int result);
     if (result == 1)
     {
         UserFeedback = Feedback.Good;
     }
     else if (result == -1)
     {
         UserFeedback = Feedback.Bad;
     }
     else
     {
         UserFeedback = Feedback.Medium;
     }
     _window.DialogResult = true;
     _window.Close();
 }