From 32a9da8a0261b8ba53bc554058e1d764a5948c6d Mon Sep 17 00:00:00 2001 From: Michael Becker Date: Tue, 23 Feb 2021 23:40:48 -0500 Subject: [PATCH] notify application when a command is enabled or disabled --- MBS.Framework/Command.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/MBS.Framework/Command.cs b/MBS.Framework/Command.cs index 1802cb7..b3e1ca0 100644 --- a/MBS.Framework/Command.cs +++ b/MBS.Framework/Command.cs @@ -79,7 +79,8 @@ namespace MBS.Framework /// that reference it. /// /// true if visible; otherwise, false. - public bool Enabled { get; set; } = true; + private bool _Enabled = true; + public bool Enabled { get { return _Enabled; } set { _Enabled = value; Application.Instance._EnableDisableCommand(this, value); } } /// /// Determines whether this is visible in all s and s