diff options
| author | Roy Ben Shabat <Roy.mail.net@gmail.com> | 2020-04-14 06:23:25 +0300 |
|---|---|---|
| committer | Roy Ben Shabat <Roy.mail.net@gmail.com> | 2020-04-14 06:23:25 +0300 |
| commit | 8f738753289dcb7118162122c5404d2a02b305f7 (patch) | |
| tree | aba06cb5c9def702af9cf791ce0a65cb2684af07 /Software/Visual_Studio/Tango.SharedUI/DialogViewVM.cs | |
| parent | 76ebe53d89a1b0cbf21d66dc9f26dc95cc7b3be9 (diff) | |
| download | Tango-8f738753289dcb7118162122c5404d2a02b305f7.tar.gz Tango-8f738753289dcb7118162122c5404d2a02b305f7.zip | |
FSE Tup/Tfp & WaitForReconnection.
Diffstat (limited to 'Software/Visual_Studio/Tango.SharedUI/DialogViewVM.cs')
| -rw-r--r-- | Software/Visual_Studio/Tango.SharedUI/DialogViewVM.cs | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/Software/Visual_Studio/Tango.SharedUI/DialogViewVM.cs b/Software/Visual_Studio/Tango.SharedUI/DialogViewVM.cs index bf75fd6ef..ae6d54bc6 100644 --- a/Software/Visual_Studio/Tango.SharedUI/DialogViewVM.cs +++ b/Software/Visual_Studio/Tango.SharedUI/DialogViewVM.cs @@ -97,5 +97,22 @@ namespace Tango.SharedUI IsVisible = false; Canceled?.Invoke(); } + + /// <summary> + /// Closes the dialog with the specified result. + /// </summary> + /// <param name="result">if set to <c>true</c> accepted.</param> + public void Close(bool result) + { + DialogResult = result; + if (result) + { + Accept(); + } + else + { + Cancel(); + } + } } } |
