Choice IDisplay.OfferChoice(string message, Choice[] choices)
{
Dispatcher.Invoke(DispatcherPriority.Background, new Action(() =>
{
CreateChoiceButtons(choices);
PromptLabel.Content = message;
PromptControl.Visibility = Visibility.Visible;
}));
offeredChoices = choices;
// Wait until an option is chosen
waitForChoice.Reset();
waitForChoice.WaitOne();
return selectedChoice;
}