更新 Dialog弹出框模式
This commit is contained in:
1 parent
74e59b4892
commit
dd512a0dcb
13 files changed
+988
-2
No files matched your search
@@ -0,0 +1,44 @@
|
||||
namespace Prism.Services.Dialogs
|
||||
{
|
||||
/// <summary>
|
||||
/// An <see cref="IDialogResult"/> that contains <see cref="IDialogParameters"/> from the dialog
|
||||
/// and the <see cref="ButtonResult"/> of the dialog.
|
||||
/// </summary>
|
||||
public class DialogResult : IDialogResult
|
||||
{
|
||||
/// <summary>
|
||||
/// The parameters from the dialog.
|
||||
/// </summary>
|
||||
public IDialogParameters Parameters { get; private set; } = new DialogParameters();
|
||||
|
||||
/// <summary>
|
||||
/// The result of the dialog.
|
||||
/// </summary>
|
||||
public ButtonResult Result { get; private set; } = ButtonResult.None;
|
||||
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="DialogResult"/> class.
|
||||
/// </summary>
|
||||
public DialogResult() { }
|
||||
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="DialogResult"/> class.
|
||||
/// </summary>
|
||||
/// <param name="result">The result of the dialog.</param>
|
||||
public DialogResult(ButtonResult result)
|
||||
{
|
||||
Result = result;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="DialogResult"/> class.
|
||||
/// </summary>
|
||||
/// <param name="result">The result of the dialog.</param>
|
||||
/// <param name="parameters">The parameters from the dialog.</param>
|
||||
public DialogResult(ButtonResult result, IDialogParameters parameters)
|
||||
{
|
||||
Result = result;
|
||||
Parameters = parameters;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user