Project Maintenance

This commit is contained in:
Gustave Monce
2021-08-09 20:21:09 +02:00
parent 9865ef7f79
commit 847ce0506d
411 changed files with 5922 additions and 54941 deletions
+3 -14
View File
@@ -26,7 +26,7 @@ namespace WPinternals
{
internal class DisclaimerAndNdaViewModel : ContextViewModel
{
Action Accepted;
private readonly Action Accepted;
internal DisclaimerAndNdaViewModel(Action Accepted)
: base()
@@ -39,14 +39,7 @@ namespace WPinternals
{
get
{
if (_ExitCommand == null)
{
_ExitCommand = new DelegateCommand(() =>
{
Application.Current.Shutdown();
});
}
return _ExitCommand;
return _ExitCommand ??= new DelegateCommand(() => Application.Current.Shutdown());
}
}
@@ -55,16 +48,12 @@ namespace WPinternals
{
get
{
if (_ContinueCommand == null)
{
_ContinueCommand = new DelegateCommand(() =>
return _ContinueCommand ??= new DelegateCommand(() =>
{
Registry.CurrentUser.OpenSubKey("Software\\WPInternals", true).SetValue("DisclaimerAccepted", 1, RegistryValueKind.DWord);
Registry.CurrentUser.OpenSubKey("Software\\WPInternals", true).SetValue("NdaAccepted", 1, RegistryValueKind.DWord);
Accepted();
});
}
return _ContinueCommand;
}
}
}