Interface IDialogPresenter
Represents a presenter that can show dialogs. Implemented by both INavigator and IDialogNavigator (to show top-level and child dialogs, respectively).
Namespace: Singulink.UI.Navigation
Assembly: Singulink.UI.Navigation.dll
Syntax
public interface IDialogPresenter
Properties
| Name | Description |
|---|---|
| CanShowDialog | Gets a value indicating whether this presenter can currently show a dialog. This is false for a navigator while any dialog is showing, for a dialog navigator whose dialog is not the top showing dialog, and for any presenter while showing dialogs is blocked (e.g. during navigation lifecycle methods that do not permit dialogs). |
| RootServices | Gets the root service provider. This property can be accessed from any thread. |
| TaskRunner | Gets the task runner for this presenter. This property can be accessed from any thread. |
Methods
| Name | Description |
|---|---|
| CreateDialogViewModel<TViewModel>(params object?[]) | Creates a dialog view model with constructor injection, the same way the navigator creates routed view models. Explicit arguments are matched to
constructor parameters by type (positionally among parameters of the same type); remaining parameters are resolved from child services registered
by the dialogs this presenter is nested in and by the active route's view models (nearest first), then from RootServices, then from
parameter default values. The view model's |
| ShowDialogAsync(IDialogViewModel) | Shows a dialog with the specified view model and returns a task that completes when the dialog closes. |
| ShowDialogAsync<TResult>(IDialogViewModel<TResult>) | Shows a dialog with the specified view model and returns a task that completes with the dialog result when the dialog closes. |