public static MessageBoxResult Show(string caption, string title, MessageBoxButton button)
        {
            var win = new MessageView()
            {
                MessageText   = caption,
                Title         = title,
                MessageButton = button,
            };

            win.ShowDialog();
            var result = win.Result;

            win.Close();
            win = null;

            return(result);
        }
Esempio n. 2
0
 public bool GetResponse(string forChallenge)
 {
     return(MessageView.Show(forChallenge, "Please confirm...", MessageBoxButton.YesNo) == MessageBoxResult.Yes);
 }