From 5bdce08d49aedb692c8b536ccf38972657b02861 Mon Sep 17 00:00:00 2001 From: BDisp Date: Fri, 17 Mar 2023 17:02:54 +0000 Subject: [PATCH] Grouping Wizard events in WizardEventArgs.cs file. --- Terminal.Gui/Windows/StepChangeEventArgs.cs | 38 ------------- Terminal.Gui/Windows/WizardButtonEventArgs.cs | 24 --------- Terminal.Gui/Windows/WizardEventArgs.cs | 54 +++++++++++++++++++ 3 files changed, 54 insertions(+), 62 deletions(-) delete mode 100644 Terminal.Gui/Windows/StepChangeEventArgs.cs delete mode 100644 Terminal.Gui/Windows/WizardButtonEventArgs.cs create mode 100644 Terminal.Gui/Windows/WizardEventArgs.cs diff --git a/Terminal.Gui/Windows/StepChangeEventArgs.cs b/Terminal.Gui/Windows/StepChangeEventArgs.cs deleted file mode 100644 index 9bbc0e240..000000000 --- a/Terminal.Gui/Windows/StepChangeEventArgs.cs +++ /dev/null @@ -1,38 +0,0 @@ -using System; - -namespace Terminal.Gui { - - public partial class Wizard { - /// - /// for events. - /// - public class StepChangeEventArgs : EventArgs { - /// - /// The current (or previous) . - /// - public WizardStep OldStep { get; } - - /// - /// The the is changing to or has changed to. - /// - public WizardStep NewStep { get; } - - /// - /// Event handlers can set to true before returning to cancel the step transition. - /// - public bool Cancel { get; set; } - - /// - /// Initializes a new instance of - /// - /// The current . - /// The new . - public StepChangeEventArgs (WizardStep oldStep, WizardStep newStep) - { - OldStep = oldStep; - NewStep = newStep; - Cancel = false; - } - } - } -} \ No newline at end of file diff --git a/Terminal.Gui/Windows/WizardButtonEventArgs.cs b/Terminal.Gui/Windows/WizardButtonEventArgs.cs deleted file mode 100644 index 277aa672f..000000000 --- a/Terminal.Gui/Windows/WizardButtonEventArgs.cs +++ /dev/null @@ -1,24 +0,0 @@ -using System; - -namespace Terminal.Gui { - - public partial class Wizard { - /// - /// for transition events. - /// - public class WizardButtonEventArgs : EventArgs { - /// - /// Set to true to cancel the transition to the next step. - /// - public bool Cancel { get; set; } - - /// - /// Initializes a new instance of - /// - public WizardButtonEventArgs () - { - Cancel = false; - } - } - } -} \ No newline at end of file diff --git a/Terminal.Gui/Windows/WizardEventArgs.cs b/Terminal.Gui/Windows/WizardEventArgs.cs new file mode 100644 index 000000000..a1afa75bc --- /dev/null +++ b/Terminal.Gui/Windows/WizardEventArgs.cs @@ -0,0 +1,54 @@ +using System; +using static Terminal.Gui.Wizard; + +namespace Terminal.Gui { + /// + /// for transition events. + /// + public class WizardButtonEventArgs : EventArgs { + /// + /// Set to true to cancel the transition to the next step. + /// + public bool Cancel { get; set; } + + /// + /// Initializes a new instance of + /// + public WizardButtonEventArgs () + { + Cancel = false; + } + } + + /// + /// for events. + /// + public class StepChangeEventArgs : EventArgs { + /// + /// The current (or previous) . + /// + public WizardStep OldStep { get; } + + /// + /// The the is changing to or has changed to. + /// + public WizardStep NewStep { get; } + + /// + /// Event handlers can set to true before returning to cancel the step transition. + /// + public bool Cancel { get; set; } + + /// + /// Initializes a new instance of + /// + /// The current . + /// The new . + public StepChangeEventArgs (WizardStep oldStep, WizardStep newStep) + { + OldStep = oldStep; + NewStep = newStep; + Cancel = false; + } + } +}