diff options
| author | Shlomo Hecht <shlomo@twine-s.com> | 2019-05-03 10:08:08 +0300 |
|---|---|---|
| committer | Shlomo Hecht <shlomo@twine-s.com> | 2019-05-03 10:08:08 +0300 |
| commit | ec4baf29ede89bf4290f52578df517dc784cb71c (patch) | |
| tree | edfdf93b1394a15529ee28e57b2b31aa5044fa99 /Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/ViewModels | |
| parent | 12aeb0e61bc3f177a9b85a6067d4909e925c8326 (diff) | |
| parent | 0b593edbbd1ba4072d7a18a9395acdb5b8c21693 (diff) | |
| download | Tango-ec4baf29ede89bf4290f52578df517dc784cb71c.tar.gz Tango-ec4baf29ede89bf4290f52578df517dc784cb71c.zip | |
Merge branch 'master' of https://twinetfs.visualstudio.com/Tango/_git/Tango
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 | 27 |
1 files changed, 27 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 c858e982e..b413fee0d 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 @@ -86,6 +86,27 @@ namespace Tango.PPC.MachineSettings.ViewModels set { _enableRemoteAssistance = value; RaisePropertyChangedAuto(); OnEnableRemoteAssistanceChanged(); } } + private bool _enableLockScreen; + public bool EnableLockScreen + { + get { return _enableLockScreen; } + set { _enableLockScreen = value; RaisePropertyChangedAuto(); } + } + + private int _lockScreenTimeoutMinutes; + public int LockScreenTimeoutMinutes + { + get { return _lockScreenTimeoutMinutes; } + set { _lockScreenTimeoutMinutes = value; RaisePropertyChangedAuto(); } + } + + private String _lockScreenPassword; + public String LockScreenPassword + { + get { return _lockScreenPassword; } + set { _lockScreenPassword = value; RaisePropertyChangedAuto(); } + } + #endregion #region Commands @@ -125,6 +146,9 @@ namespace Tango.PPC.MachineSettings.ViewModels Settings.HotSpotPassword = HotSpotPassword; Settings.EnableExternalBridge = EnableExternalBridge; Settings.ExternalBridgePassword = ExternalBridgePassword; + Settings.EnableLockScreen = EnableLockScreen; + Settings.LockScreenTimeout = TimeSpan.FromMinutes(LockScreenTimeoutMinutes); + Settings.LockScreenPassword = LockScreenPassword; Settings.Save(); await MachineProvider.SaveMachine(); @@ -166,6 +190,9 @@ namespace Tango.PPC.MachineSettings.ViewModels _enableRemoteAssistance = RemoteAssistanceProvider.IsEnabled; RaisePropertyChanged(nameof(EnableRemoteAssistance)); + EnableLockScreen = Settings.EnableLockScreen; + LockScreenTimeoutMinutes = (int)Settings.LockScreenTimeout.TotalMinutes; + LockScreenPassword = Settings.LockScreenPassword; SelectedJobTypes = new SelectedObjectCollection<JobTypes>(Enum.GetValues(typeof(JobTypes)).Cast<JobTypes>().ToObservableCollection(), Machine.SupportedJobTypes.ToObservableCollection()); SelectedColorSpaces = new SelectedObjectCollection<ColorSpaces>(Enum.GetValues(typeof(ColorSpaces)).Cast<ColorSpaces>().Where(x => x.IsUserSpace()).ToObservableCollection(), Machine.SupportedColorSpaces.ToObservableCollection()); |
