diff options
Diffstat (limited to 'Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/ViewModels')
| -rw-r--r-- | Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/ViewModels/MainViewVM.cs | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/ViewModels/MainViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/ViewModels/MainViewVM.cs index f4bbf6da3..523934985 100644 --- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/ViewModels/MainViewVM.cs +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/ViewModels/MainViewVM.cs @@ -227,6 +227,13 @@ namespace Tango.PPC.MachineSettings.ViewModels set { _lubricationLevels = value; RaisePropertyChangedAuto(); } } + private RmlLubricationLevelSettings _selectedLubricationLevel; + public RmlLubricationLevelSettings SelectedLubricationLevel + { + get { return _selectedLubricationLevel; } + set { _selectedLubricationLevel = value; RaisePropertyChangedAuto(); } + } + #endregion #region Commands @@ -445,6 +452,15 @@ namespace Tango.PPC.MachineSettings.ViewModels } LubricationLevels = levels; + + if (SelectedLubricationLevel != null) + { + SelectedLubricationLevel = LubricationLevels.FirstOrDefault(x => x.RmlGuid == SelectedLubricationLevel.RmlGuid); + } + else + { + SelectedLubricationLevel = LubricationLevels.FirstOrDefault(); + } } catch (Exception ex) { |
