Skip to content

Commit

Permalink
..
Browse files Browse the repository at this point in the history
  • Loading branch information
Sereoj committed Jan 30, 2021
1 parent 7b1ca2a commit 23d5d67
Showing 1 changed file with 90 additions and 88 deletions.
178 changes: 90 additions & 88 deletions Test/ViewModels/FirstSettingsViewModel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,8 @@ private void OnUpdateCheckBoxCommandExecuted(object p)
var checkbox = p as CheckBox;
var isChecked = checkbox?.IsChecked;


LastActiveCheckBox = checkbox;
if(checkbox != null)
LastActiveCheckBox = checkbox;

switch (checkbox.Name)
{
Expand Down Expand Up @@ -191,93 +191,95 @@ public FirstSettingsViewModel()

private void UpdateSettings(CheckBox lastActiveCheckBox)
{

switch (lastActiveCheckBox.Name)
if (lastActiveCheckBox != null)
{
case "CheckFormat1":
Model.Items[0].Catalog = UpdateTextDirectory;
Model.Items[0].Extension = UpdateTextExtension;
break;
case "CheckFormat2":
Model.Items[1].Catalog = UpdateTextDirectory;
Model.Items[1].Extension = UpdateTextExtension;
break;
case "CheckFormat3":
Model.Items[2].Catalog = UpdateTextDirectory;
Model.Items[2].Extension = UpdateTextExtension;
break;
case "CheckFormat4":
Model.Items[3].Catalog = UpdateTextDirectory;
Model.Items[3].Extension = UpdateTextExtension;
break;
case "CheckFormat5":
Model.Items[4].Catalog = UpdateTextDirectory;
Model.Items[4].Extension = UpdateTextExtension;
break;
case "CheckFormat6":
Model.Items[5].Catalog = UpdateTextDirectory;
Model.Items[5].Extension = UpdateTextExtension;
break;
case "CheckFormat7":
Model.Items[6].Catalog = UpdateTextDirectory;
Model.Items[6].Extension = UpdateTextExtension;
break;
case "CheckFormat8":
Model.Items[7].Catalog = UpdateTextDirectory;
Model.Items[7].Extension = UpdateTextExtension;
break;
case "CheckFormat9":
Model.Items[8].Catalog = UpdateTextDirectory;
Model.Items[8].Extension = UpdateTextExtension;
break;
case "CheckFormat10":
Model.Items[9].Catalog = UpdateTextDirectory;
Model.Items[9].Extension = UpdateTextExtension;
break;
case "CheckFormat11":
Model.Items[10].Catalog = UpdateTextDirectory;
Model.Items[10].Extension = UpdateTextExtension;
break;
case "CheckFormat12":
Model.Items[11].Catalog = UpdateTextDirectory;
Model.Items[11].Extension = UpdateTextExtension;
break;
case "CheckFormat13":
Model.Items[12].Catalog = UpdateTextDirectory;
Model.Items[12].Extension = UpdateTextExtension;
break;
case "CheckFormat14":
Model.Items[13].Catalog = UpdateTextDirectory;
Model.Items[13].Extension = UpdateTextExtension;
break;
case "CheckFormat15":
Model.Items[14].Catalog = UpdateTextDirectory;
Model.Items[14].Extension = UpdateTextExtension;
break;
case "CheckFormat16":
Model.Items[15].Catalog = UpdateTextDirectory;
Model.Items[15].Extension = UpdateTextExtension;
break;
case "CheckFormat17":
Model.Items[16].Catalog = UpdateTextDirectory;
Model.Items[16].Extension = UpdateTextExtension;
break;
case "CheckFormat18":
Model.Items[17].Catalog = UpdateTextDirectory;
Model.Items[17].Extension = UpdateTextExtension;
break;
case "CheckFormat19":
Model.Items[18].Catalog = UpdateTextDirectory;
Model.Items[18].Extension = UpdateTextExtension;
break;
case "CheckFormat20":
Model.Items[19].Catalog = UpdateTextDirectory;
Model.Items[19].Extension = UpdateTextExtension;
break;
case "CheckFormat21":
Model.Items[20].Catalog = UpdateTextDirectory;
Model.Items[20].Extension = UpdateTextExtension;
break;
switch (lastActiveCheckBox.Name)
{
case "CheckFormat1":
Model.Items[0].Catalog = UpdateTextDirectory;
Model.Items[0].Extension = UpdateTextExtension;
break;
case "CheckFormat2":
Model.Items[1].Catalog = UpdateTextDirectory;
Model.Items[1].Extension = UpdateTextExtension;
break;
case "CheckFormat3":
Model.Items[2].Catalog = UpdateTextDirectory;
Model.Items[2].Extension = UpdateTextExtension;
break;
case "CheckFormat4":
Model.Items[3].Catalog = UpdateTextDirectory;
Model.Items[3].Extension = UpdateTextExtension;
break;
case "CheckFormat5":
Model.Items[4].Catalog = UpdateTextDirectory;
Model.Items[4].Extension = UpdateTextExtension;
break;
case "CheckFormat6":
Model.Items[5].Catalog = UpdateTextDirectory;
Model.Items[5].Extension = UpdateTextExtension;
break;
case "CheckFormat7":
Model.Items[6].Catalog = UpdateTextDirectory;
Model.Items[6].Extension = UpdateTextExtension;
break;
case "CheckFormat8":
Model.Items[7].Catalog = UpdateTextDirectory;
Model.Items[7].Extension = UpdateTextExtension;
break;
case "CheckFormat9":
Model.Items[8].Catalog = UpdateTextDirectory;
Model.Items[8].Extension = UpdateTextExtension;
break;
case "CheckFormat10":
Model.Items[9].Catalog = UpdateTextDirectory;
Model.Items[9].Extension = UpdateTextExtension;
break;
case "CheckFormat11":
Model.Items[10].Catalog = UpdateTextDirectory;
Model.Items[10].Extension = UpdateTextExtension;
break;
case "CheckFormat12":
Model.Items[11].Catalog = UpdateTextDirectory;
Model.Items[11].Extension = UpdateTextExtension;
break;
case "CheckFormat13":
Model.Items[12].Catalog = UpdateTextDirectory;
Model.Items[12].Extension = UpdateTextExtension;
break;
case "CheckFormat14":
Model.Items[13].Catalog = UpdateTextDirectory;
Model.Items[13].Extension = UpdateTextExtension;
break;
case "CheckFormat15":
Model.Items[14].Catalog = UpdateTextDirectory;
Model.Items[14].Extension = UpdateTextExtension;
break;
case "CheckFormat16":
Model.Items[15].Catalog = UpdateTextDirectory;
Model.Items[15].Extension = UpdateTextExtension;
break;
case "CheckFormat17":
Model.Items[16].Catalog = UpdateTextDirectory;
Model.Items[16].Extension = UpdateTextExtension;
break;
case "CheckFormat18":
Model.Items[17].Catalog = UpdateTextDirectory;
Model.Items[17].Extension = UpdateTextExtension;
break;
case "CheckFormat19":
Model.Items[18].Catalog = UpdateTextDirectory;
Model.Items[18].Extension = UpdateTextExtension;
break;
case "CheckFormat20":
Model.Items[19].Catalog = UpdateTextDirectory;
Model.Items[19].Extension = UpdateTextExtension;
break;
case "CheckFormat21":
Model.Items[20].Catalog = UpdateTextDirectory;
Model.Items[20].Extension = UpdateTextExtension;
break;
}
}
}

Expand Down

0 comments on commit 23d5d67

Please sign in to comment.