private List<CustomCommandViewModel> CreateCustomCommandView() { List<CustomCommandViewModel> l = new List<CustomCommandViewModel>(); foreach (var customCommand in this.j64Config.CustomCommands) { var ccvm = new CustomCommandViewModel() { CommandName = customCommand.CommandName }; int i = 1; foreach (var ca in customCommand.Actions) { var cc = new ViewModels.Configure.CustomCommand() { Sequence = i, Device = ca.Device, ControlGroup = ca.Group, Function = ca.Function }; ccvm.commands.Add(cc); i++; } l.Add(ccvm); } return l; }
private List <CustomCommandViewModel> CreateCustomCommandView() { List <CustomCommandViewModel> l = new List <CustomCommandViewModel>(); foreach (var customCommand in this.j64Config.CustomCommands) { var ccvm = new CustomCommandViewModel() { CommandName = customCommand.CommandName }; int i = 1; foreach (var ca in customCommand.Actions) { var cc = new ViewModels.Configure.CustomCommand() { Sequence = i, Device = ca.Device, ControlGroup = ca.Group, Function = ca.Function }; ccvm.commands.Add(cc); i++; } l.Add(ccvm); } return(l); }