Beispiel #1
0
        public static async Task <DialogResult> ShowDialog_YesNoCancel(string title, string content)
        {
            var prompt = new DialogPrompt();

            prompt.DialogTitle.Text = title;
            prompt.DialogText.Text  = content;

            ConfigManager.MainThread.SetDialogFrame(prompt);

            return(await Task.Run(prompt.DialogWait));
        }
Beispiel #2
0
        public static async Task <DialogResult> ShowDialog_YesNo(string title, string content, params object[] args)
        {
            var prompt = new DialogPrompt();

            prompt.DialogTitle.Text = string.Format(title, args);
            prompt.DialogText.Text  = string.Format(content, args);

            prompt.CancelButton.Visibility = Visibility.Collapsed;

            ConfigManager.MainThread.SetDialogFrame(prompt);

            return(await Task.Run(prompt.DialogWait));
        }