Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/xwt.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVsevolod Kukol <sevoku@microsoft.com>2016-09-20 01:33:31 +0300
committerVsevolod Kukol <sevoku@microsoft.com>2016-09-20 01:33:31 +0300
commitdbac8c7b800a86c1ef9af7c31c101b9123a64a3e (patch)
tree981529cc1b85485b4778874395f286e547510f67 /TestApps
parent61e27e08130f495ab2118730c61b2008aa88f593 (diff)
Add Dialog.DefaultCommand property
The DefaultCommand property sets a command to be the default button of the dialog. Depending on the platform the button will be added at the end of the button list and/or have a different appearance.
Diffstat (limited to 'TestApps')
-rw-r--r--TestApps/Samples/Samples/Windows.cs2
1 files changed, 2 insertions, 0 deletions
diff --git a/TestApps/Samples/Samples/Windows.cs b/TestApps/Samples/Samples/Windows.cs
index dc236ae4..765faab4 100644
--- a/TestApps/Samples/Samples/Windows.cs
+++ b/TestApps/Samples/Samples/Windows.cs
@@ -74,6 +74,8 @@ namespace Samples
d.Buttons.Add (new DialogButton (Command.Cancel));
d.Buttons.Add (new DialogButton (Command.Ok));
+ d.DefaultCommand = custom;
+
d.CommandActivated += (sender, e) => {
if (e.Command == custom) {
e.Handled = !MessageDialog.Confirm ("Really close?", Command.Close);