This commit is contained in:
NaBian committed 2019-09-18 21:49:37 +08:00
1 parent 846ab427ef
commit 6e1d294202
6 files changed
+97 -26

No files matched your search

@@ -52,14 +52,16 @@ namespace HandyControl.Controls
Info = Text
});
if (Command == null) return;
if (Command is RoutedCommand command)
switch (Command)
{
command.Execute(CommandParameter, CommandTarget);
}
else
{
Command.Execute(CommandParameter);
case null:
return;
case RoutedCommand command:
command.Execute(CommandParameter, CommandTarget);
break;
default:
Command.Execute(CommandParameter);
break;
}
}