public virtual Task <PromptResult> PromptAsync(PromptConfig config)
        {
            var tcs = new TaskCompletionSource <PromptResult>();

            config.OnResult = x => tcs.TrySetResult(x);
            this.Prompt(config);
            return(tcs.Task);
        }
 //public abstract void DateTimePrompt(DateTimePromptConfig config);
 //public abstract void DurationPrompt(DurationPromptConfig config);
 public abstract void Prompt(PromptConfig config);
 public static Task<PromptResult> PromptAsync(this IUserDialogService dialogs, PromptConfig config) {
     var tcs = new TaskCompletionSource<PromptResult>();
     config.OnResult = tcs.SetResult;
     dialogs.Prompt(config);
     return tcs.Task;
 }
Example #4
0
 //public abstract void DateTimePrompt(DateTimePromptConfig config);
 //public abstract void DurationPrompt(DurationPromptConfig config);
 public abstract void Prompt(PromptConfig config);
Example #5
0
        public static Task <PromptResult> PromptAsync(this IUserDialogService dialogs, PromptConfig config)
        {
            var tcs = new TaskCompletionSource <PromptResult>();

            config.OnResult = tcs.SetResult;
            dialogs.Prompt(config);
            return(tcs.Task);
        }