aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings
diff options
context:
space:
mode:
Diffstat (limited to 'Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings')
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/MachineSettingsModule.cs2
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/ViewModels/MainViewVM.cs229
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/Views/MainView.xaml186
3 files changed, 16 insertions, 401 deletions
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/MachineSettingsModule.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/MachineSettingsModule.cs
index 807a70b10..477340357 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/MachineSettingsModule.cs
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/MachineSettingsModule.cs
@@ -15,7 +15,7 @@ namespace Tango.PPC.MachineSettings
/// Represents a PPC <see cref="MachineSettingsModule"/>.
/// </summary>
/// <seealso cref="Tango.PPC.Common.PPCModuleBase" />
- [PPCModule(4)]
+ [PPCModule(2)]
public class MachineSettingsModule : PPCModuleBase
{
/// <summary>
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 20cfd6bf4..8ed512670 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
@@ -9,7 +9,6 @@ using System.Text;
using System.Threading.Tasks;
using System.Windows.Data;
using Tango.BL;
-using Tango.BL.Builders;
using Tango.BL.Entities;
using Tango.BL.Enumerations;
using Tango.Core.Commands;
@@ -19,8 +18,6 @@ using Tango.PPC.Common;
using Tango.PPC.Common.Connection;
using Tango.PPC.Common.ExternalBridge;
using Tango.PPC.Common.Messages;
-using Tango.PPC.Common.OS;
-using Tango.PPC.Common.UWF;
using Tango.SharedUI.Components;
using Tango.WiFi;
@@ -32,17 +29,8 @@ namespace Tango.PPC.MachineSettings.ViewModels
/// <seealso cref="Tango.PPC.Common.PPCViewModel" />
public class MainViewVM : PPCViewModel
{
- private TimeZoneInfo _previousTimeZone;
- private bool _previousEnableUWF;
-
#region Properties
- [TangoInject]
- private IOperationSystemManager OperationSystemManager { get; set; }
-
- [TangoInject]
- private IUnifiedWriteFilterManager UnifiedWriteFilterManager { get; set; }
-
private Machine _machine;
public Machine Machine
{
@@ -64,13 +52,6 @@ namespace Tango.PPC.MachineSettings.ViewModels
set { _selectedColorSpaces = value; RaisePropertyChangedAuto(); }
}
- private ObservableCollection<Rml> _rmls;
- public ObservableCollection<Rml> Rmls
- {
- get { return _rmls; }
- set { _rmls = value; RaisePropertyChangedAuto(); }
- }
-
private bool _enableHotSpot;
public bool EnableHotSpot
{
@@ -127,69 +108,6 @@ namespace Tango.PPC.MachineSettings.ViewModels
set { _lockScreenPassword = value; RaisePropertyChangedAuto(); }
}
- private Rml _defaultRML;
- public Rml DefaultRML
- {
- get { return _defaultRML; }
- set { _defaultRML = value; RaisePropertyChangedAuto(); }
- }
-
- private SpoolType _defaultSpoolType;
- public SpoolType DefaultSpoolType
- {
- get { return _defaultSpoolType; }
- set { _defaultSpoolType = value; RaisePropertyChangedAuto(); }
- }
-
- private bool _synchronizeJobs;
- public bool SynchronizeJobs
- {
- get { return _synchronizeJobs; }
- set { _synchronizeJobs = value; RaisePropertyChangedAuto(); InvalidateRelayCommands(); }
- }
-
- private bool _synchronizeDiagnostics;
- public bool SynchronizeDiagnostics
- {
- get { return _synchronizeDiagnostics; }
- set { _synchronizeDiagnostics = value; RaisePropertyChangedAuto(); InvalidateRelayCommands(); }
- }
-
- private bool _autoCheckForUpdates;
- public bool AutoCheckForUpdates
- {
- get { return _autoCheckForUpdates; }
- set { _autoCheckForUpdates = value; RaisePropertyChangedAuto(); }
- }
-
- private List<TimeZoneInfo> _timeZones;
- /// <summary>
- /// Gets or sets the available time zones.
- /// </summary>
- public List<TimeZoneInfo> TimeZones
- {
- get { return _timeZones; }
- set { _timeZones = value; RaisePropertyChangedAuto(); }
- }
-
- private TimeZoneInfo _selectedTimeZone;
- /// <summary>
- /// Gets or sets the selected time zone.
- /// </summary>
- public TimeZoneInfo SelectedTimeZone
- {
- get { return _selectedTimeZone; }
- set { _selectedTimeZone = value; RaisePropertyChangedAuto(); }
- }
-
- private bool _enableUWF;
- public bool EnableUWF
- {
- get { return _enableUWF; }
- set { _enableUWF = value; RaisePropertyChangedAuto(); }
- }
-
-
#endregion
#region Commands
@@ -204,18 +122,12 @@ namespace Tango.PPC.MachineSettings.ViewModels
/// </summary>
public RelayCommand DiscardCommand { get; set; }
- /// <summary>
- /// Gets or sets the synchronize command.
- /// </summary>
- public RelayCommand SynchronizeCommand { get; set; }
-
#endregion
public MainViewVM()
{
SaveCommand = new RelayCommand(Save);
DiscardCommand = new RelayCommand(Discard);
- SynchronizeCommand = new RelayCommand(Synchronize, () => !MachineDataSynchronizer.IsSynchronizing && IsFree);
}
private void Discard()
@@ -227,9 +139,9 @@ namespace Tango.PPC.MachineSettings.ViewModels
{
if (Validate())
{
- Settings.SupportedJobTypes = SelectedJobTypes.SynchedSource.ToList();
- Settings.SupportedColorSpaces = SelectedColorSpaces.SynchedSource.ToList();
- Machine.MapPropertiesTo(MachineProvider.Machine, MappingFlags.NoReferenceTypes);
+ Machine.SupportedJobTypes = SelectedJobTypes.SynchedSource.ToList();
+ Machine.SupportedColorSpaces = SelectedColorSpaces.SynchedSource.ToList();
+ Machine.MapPrimitivesWithStrings(MachineProvider.Machine);
Settings.EnableHotSpot = EnableHotSpot;
Settings.HotSpotPassword = HotSpotPassword;
@@ -238,73 +150,10 @@ namespace Tango.PPC.MachineSettings.ViewModels
Settings.EnableLockScreen = EnableLockScreen;
Settings.LockScreenTimeout = TimeSpan.FromMinutes(LockScreenTimeoutMinutes);
Settings.LockScreenPassword = LockScreenPassword;
- Settings.DefaultRmlGuid = DefaultRML?.Guid;
- Settings.DefaultSpoolTypeGuid = DefaultSpoolType?.Guid;
- Settings.SynchronizeJobs = SynchronizeJobs;
- Settings.SynchronizeDiagnostics = SynchronizeDiagnostics;
- Settings.AutoCheckForUpdates = AutoCheckForUpdates;
-
- MachineDataSynchronizer.IsEnabled = SynchronizeJobs || SynchronizeDiagnostics;
-
Settings.Save();
await MachineProvider.SaveMachine();
-
- bool isRestarting = false;
-
- if (_previousTimeZone.ToStringSafe() != SelectedTimeZone.ToStringSafe())
- {
- if (await NotificationProvider.ShowQuestion("Changing the time zone requires the application to restart. Do you wish to restart the application?"))
- {
- try
- {
- LogManager.Log($"Setting new time zone to '{SelectedTimeZone.ToString()}'.");
- NotificationProvider.SetGlobalBusyMessage("Setting new time zone...");
- await OperationSystemManager.ChangeTimeZone(SelectedTimeZone);
- NotificationProvider.ReleaseGlobalBusyMessage();
- isRestarting = true;
- ApplicationManager.Restart();
- }
- catch (Exception ex)
- {
- LogManager.Log(ex, "Error changing the time zone.");
- NotificationProvider.ReleaseGlobalBusyMessage();
- await NotificationProvider.ShowError($"Error setting timezone.\n{ex.FlattenMessage()}");
- }
- }
- }
-
- if (_previousEnableUWF != EnableUWF)
- {
- await NotificationProvider.ShowWarning("Changes to disk protection (UWF) will take effect only after a full system restart.");
-
- try
- {
- LogManager.Log($"Changing UWF mode to '{EnableUWF}'.");
- if (EnableUWF)
- {
- NotificationProvider.SetGlobalBusyMessage("Enabling disk protection (UWF)...");
- await UnifiedWriteFilterManager.Enable();
- }
- else
- {
- NotificationProvider.SetGlobalBusyMessage("Disabling disk protection (UWF)...");
- await UnifiedWriteFilterManager.Disable();
- }
- NotificationProvider.ReleaseGlobalBusyMessage();
- }
- catch (Exception ex)
- {
- NotificationProvider.ReleaseGlobalBusyMessage();
- LogManager.Log(ex, "Error setting UWF mode.");
- await NotificationProvider.ShowError($"Could not change the disk protection mode\n{ex.FlattenMessage()}");
- }
- }
-
- if (!isRestarting)
- {
- await NavigationManager.NavigateBack();
- }
+ await NavigationManager.NavigateBack();
}
}
@@ -318,29 +167,10 @@ namespace Tango.PPC.MachineSettings.ViewModels
/// </summary>
public override void OnApplicationStarted()
{
- try
- {
- TimeZones = OperationSystemManager.GetAvailableTimeZones().ToList();
- }
- catch (Exception ex)
- {
- LogManager.Log(ex, "Error retrieving available time zones.");
- }
- }
-
- public async override void OnApplicationReady()
- {
- base.OnApplicationReady();
- MachineDataSynchronizer.SynchronizationStarted += (_, __) => InvalidateRelayCommands();
- MachineDataSynchronizer.SynchronizationEnded += (_, __) => InvalidateRelayCommands();
- using (ObservablesContext db = ObservablesContext.CreateDefault())
- {
- Rmls = await new RmlsCollectionBuilder(db).SetAll().ForHeadType(MachineProvider.Machine.MachineHeadType).ForSite(MachineProvider.Machine.SiteGuid).BuildAsync();
- }
}
- public async override void OnNavigatedTo()
+ public override void OnNavigatedTo()
{
base.OnNavigatedTo();
@@ -365,29 +195,8 @@ namespace Tango.PPC.MachineSettings.ViewModels
LockScreenTimeoutMinutes = (int)Settings.LockScreenTimeout.TotalMinutes;
LockScreenPassword = Settings.LockScreenPassword;
- SelectedJobTypes = new SelectedObjectCollection<JobTypes>(Enum.GetValues(typeof(JobTypes)).Cast<JobTypes>().ToObservableCollection(), Settings.SupportedJobTypes.ToObservableCollection());
- SelectedColorSpaces = new SelectedObjectCollection<ColorSpaces>(Enum.GetValues(typeof(ColorSpaces)).Cast<ColorSpaces>().Where(x => x.IsUserSpace()).ToObservableCollection(), Settings.SupportedColorSpaces.ToObservableCollection());
-
- DefaultRML = Adapter.Rmls.SingleOrDefault(x => x.Guid == Settings.DefaultRmlGuid);
- DefaultSpoolType = Adapter.SpoolTypes.SingleOrDefault(x => x.Guid == Settings.DefaultSpoolTypeGuid);
-
- SynchronizeJobs = Settings.SynchronizeJobs;
- SynchronizeDiagnostics = Settings.SynchronizeDiagnostics;
-
- AutoCheckForUpdates = Settings.AutoCheckForUpdates;
-
- SelectedTimeZone = TimeZones.SingleOrDefault(x => x.StandardName == TimeZone.CurrentTimeZone.StandardName);
- _previousTimeZone = SelectedTimeZone;
-
- try
- {
- EnableUWF = await UnifiedWriteFilterManager.IsEnabled();
- _previousEnableUWF = EnableUWF;
- }
- catch (Exception ex)
- {
- LogManager.Log(ex, "Error getting UWF status.");
- }
+ 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());
}
private async void OnEnableRemoteAssistanceChanged()
@@ -462,29 +271,5 @@ namespace Tango.PPC.MachineSettings.ViewModels
{
ExternalBridgeService.Enabled = EnableExternalBridge;
}
-
- private async void Synchronize()
- {
- try
- {
- IsFree = false;
- NotificationProvider.SetGlobalBusyMessage("Synchronizing...");
-
- await MachineDataSynchronizer.Synchronize();
-
- NotificationProvider.ReleaseGlobalBusyMessage();
- await NotificationProvider.ShowSuccess("Synchronization completed successfully.");
- }
- catch (Exception ex)
- {
- NotificationProvider.ReleaseGlobalBusyMessage();
- await NotificationProvider.ShowError($"Error occurred while trying to synchronize.\n{ex.FlattenMessage()}");
- }
- finally
- {
- NotificationProvider.ReleaseGlobalBusyMessage();
- IsFree = true;
- }
- }
}
}
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/Views/MainView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/Views/MainView.xaml
index ba3516be4..dd5f89bb2 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/Views/MainView.xaml
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.MachineSettings/Views/MainView.xaml
@@ -5,19 +5,15 @@
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:enumerations="clr-namespace:Tango.BL.Enumerations;assembly=Tango.BL"
xmlns:touch="clr-namespace:Tango.Touch.Controls;assembly=Tango.Touch"
- xmlns:keyboard="clr-namespace:Tango.Touch.Keyboard;assembly=Tango.Touch"
- xmlns:sys="clr-namespace:System.Collections;assembly=mscorlib"
xmlns:controls="clr-namespace:Tango.SharedUI.Controls;assembly=Tango.SharedUI"
xmlns:vm="clr-namespace:Tango.PPC.MachineSettings.ViewModels"
xmlns:connectivity="clr-namespace:Tango.PPC.Common.Connectivity;assembly=Tango.PPC.Common"
- xmlns:adapters="clr-namespace:Tango.Transport.Adapters;assembly=Tango.Transport"
xmlns:global="clr-namespace:Tango.PPC.MachineSettings"
- xmlns:integrationPMR="clr-namespace:Tango.PMR.Integration;assembly=Tango.PMR"
xmlns:local="clr-namespace:Tango.PPC.MachineSettings.Views"
mc:Ignorable="d"
- d:DesignHeight="4500" d:DesignWidth="800" d:DataContext="{d:DesignInstance Type=vm:MainViewVM, IsDesignTimeCreatable=False}" DataContext="{x:Static global:ViewModelLocator.MainViewVM}">
+ d:DesignHeight="2500" d:DesignWidth="800" d:DataContext="{d:DesignInstance Type=vm:MainViewVM, IsDesignTimeCreatable=False}" DataContext="{x:Static global:ViewModelLocator.MainViewVM}">
- <Grid Background="{StaticResource TangoMidBackgroundBrush}" IsEnabled="{Binding IsFree}">
+ <Grid Background="{StaticResource TangoMidBackgroundBrush}">
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="1*"/>
@@ -87,7 +83,7 @@
</touch:TouchExpander>
<!--JOBS-->
- <touch:TouchExpander Margin="0 20 0 0" Header="Jobs" IsExpanded="True" FontSize="{StaticResource TangoExpanderHeaderFontSize}">
+ <touch:TouchExpander Margin="0 20 0 0" Header="JOBS" IsExpanded="True" FontSize="{StaticResource TangoExpanderHeaderFontSize}">
<StackPanel>
<controls:TableGrid Margin="10" RowHeight="70" MakeFirstColumnVerticalAlignmentBottom="False" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
<TextBlock VerticalAlignment="Center">Supported Job Types</TextBlock>
@@ -140,14 +136,14 @@
</ItemsControl.ItemTemplate>
</ItemsControl>
- <TextBlock VerticalAlignment="Bottom">Default Thread</TextBlock>
- <touch:TouchComboBox HorizontalAlignment="Right" VerticalAlignment="Bottom" Width="200" ItemsSource="{Binding Rmls}" SelectedItem="{Binding DefaultRML}" DisplayMemberPath="Name"></touch:TouchComboBox>
+ <TextBlock VerticalAlignment="Bottom">Default Thread Type</TextBlock>
+ <touch:TouchComboBox HorizontalAlignment="Right" VerticalAlignment="Bottom" Width="200" ItemsSource="{Binding Adapter.Rmls}" SelectedItem="{Binding Machine.DefaultRml}" DisplayMemberPath="Name" ValuePath="Guid"></touch:TouchComboBox>
- <TextBlock VerticalAlignment="Bottom">Default Spool</TextBlock>
- <touch:TouchComboBox HorizontalAlignment="Right" VerticalAlignment="Bottom" Width="200" ItemsSource="{Binding Adapter.SpoolTypes}" SelectedItem="{Binding DefaultSpoolType}" DisplayMemberPath="Name"></touch:TouchComboBox>
+ <!--<TextBlock VerticalAlignment="Bottom">Default Spool</TextBlock>
+ <touch:TouchComboBox HorizontalAlignment="Right" VerticalAlignment="Bottom" Width="200" ItemsSource="{Binding Adapter.SpoolTypes}" SelectedItem="{Binding Machine.DefaultSpoolType}" DisplayMemberPath="Name"></touch:TouchComboBox>-->
<TextBlock VerticalAlignment="Bottom">Default Segment Length</TextBlock>
- <touch:TouchNumericTextBox HorizontalAlignment="Right" VerticalAlignment="Bottom" Width="200" Minimum="1" Maximum="1000" Value="{Binding Settings.DefaultSegmentLength}" HasDecimalPoint="True" KeyboardContainer="{Binding ElementName=Container}"></touch:TouchNumericTextBox>
+ <touch:TouchNumericTextBox HorizontalAlignment="Right" VerticalAlignment="Bottom" Width="200" Minimum="1" Maximum="1000" Value="{Binding Machine.DefaultSegmentLength}" HasDecimalPoint="True" KeyboardContainer="{Binding ElementName=Container}"></touch:TouchNumericTextBox>
</controls:TableGrid>
@@ -199,172 +195,6 @@
</DockPanel>
</StackPanel>
</touch:TouchExpander>
-
- <!--SYNCHRONIZATION-->
- <touch:TouchExpander Margin="0 20 0 0" Header="Cloud Synchronization" IsExpanded="True" FontSize="{StaticResource TangoExpanderHeaderFontSize}">
- <StackPanel Margin="10 30 10 10">
-
- <DockPanel TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <StackPanel>
- <TextBlock VerticalAlignment="Center">Auto Update Check</TextBlock>
- <DockPanel Margin="0 5 0 0">
- <touch:TouchIcon VerticalAlignment="Top" Icon="InformationOutline" Foreground="{StaticResource TangoGrayTextBrush}"></touch:TouchIcon>
- <TextBlock Margin="10 0 0 0" VerticalAlignment="Top" TextWrapping="Wrap" FontSize="{StaticResource TangoSmallFontSize}" Foreground="{StaticResource TangoGrayTextBrush}">
- Automatically check for software and database updates.
- </TextBlock>
- </DockPanel>
- </StackPanel>
- <touch:TouchToggleSlider Margin="0 0 100 0" DockPanel.Dock="Right" Style="{StaticResource TangoToggleButtonGrayAccent}" HorizontalAlignment="Right" Width="90" IsChecked="{Binding AutoCheckForUpdates}"></touch:TouchToggleSlider>
- </DockPanel>
-
- <DockPanel Margin="0 40 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <StackPanel>
- <TextBlock VerticalAlignment="Center">Synchronize Jobs</TextBlock>
- <DockPanel Margin="0 5 0 0">
- <touch:TouchIcon VerticalAlignment="Top" Icon="InformationOutline" Foreground="{StaticResource TangoGrayTextBrush}"></touch:TouchIcon>
- <TextBlock Margin="10 0 0 0" VerticalAlignment="Top" TextWrapping="Wrap" FontSize="{StaticResource TangoSmallFontSize}" Foreground="{StaticResource TangoGrayTextBrush}">
- Synchronize your jobs with twine's cloud services.
- </TextBlock>
- </DockPanel>
- </StackPanel>
- <touch:TouchToggleSlider Margin="0 0 100 0" DockPanel.Dock="Right" Style="{StaticResource TangoToggleButtonGrayAccent}" HorizontalAlignment="Right" Width="90" IsChecked="{Binding SynchronizeJobs}"></touch:TouchToggleSlider>
- </DockPanel>
-
- <DockPanel Margin="0 40 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <StackPanel>
- <TextBlock VerticalAlignment="Center">Synchronize Diagnostics Data</TextBlock>
- <DockPanel Margin="0 5 0 0">
- <touch:TouchIcon VerticalAlignment="Top" Icon="InformationOutline" Foreground="{StaticResource TangoGrayTextBrush}"></touch:TouchIcon>
- <TextBlock Margin="10 0 0 0" VerticalAlignment="Top" TextWrapping="Wrap" FontSize="{StaticResource TangoSmallFontSize}" Foreground="{StaticResource TangoGrayTextBrush}">
- Help us improve your experience using this system.
- </TextBlock>
- </DockPanel>
- </StackPanel>
- <touch:TouchToggleSlider Margin="0 0 100 0" DockPanel.Dock="Right" Style="{StaticResource TangoToggleButtonGrayAccent}" HorizontalAlignment="Right" Width="90" IsChecked="{Binding SynchronizeDiagnostics}"></touch:TouchToggleSlider>
- </DockPanel>
-
- <DockPanel Margin="0 40 0 0">
- <touch:TouchIcon VerticalAlignment="Top" Icon="InformationOutline" Foreground="{StaticResource TangoGrayTextBrush}"></touch:TouchIcon>
- <TextBlock Margin="10 0 0 0" VerticalAlignment="Top" TextWrapping="Wrap" FontSize="{StaticResource TangoSmallFontSize}" Foreground="{StaticResource TangoGrayTextBrush}">
- Once enabled, synchronization occurs automatically in the background. you can choose to synchronize right now.
- </TextBlock>
- </DockPanel>
- <touch:TouchButton Command="{Binding SynchronizeCommand}" IsEnabled="{Binding MachineDataSynchronizer.IsEnabled}" HorizontalAlignment="Left" Margin="25 10 0 0" Style="{StaticResource TangoHollowButton}" FontSize="{StaticResource TangoDefaultFontSize}" Padding="15 10" CornerRadius="22">Synchronize Now</touch:TouchButton>
- </StackPanel>
- </touch:TouchExpander>
-
- <!--DATE & TIME-->
- <touch:TouchExpander Margin="0 20 0 0" Header="Date &amp; Time" IsExpanded="True" FontSize="{StaticResource TangoExpanderHeaderFontSize}" Visibility="{Binding ApplicationManager.IsInTechnicianMode,Converter={StaticResource BooleanToVisibilityConverter}}">
- <StackPanel Margin="10 30 10 10">
-
- <DockPanel TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <StackPanel>
- <TextBlock VerticalAlignment="Center">Time Zone</TextBlock>
- <touch:TouchComboBox Margin="0 10 0 0" ItemsSource="{Binding TimeZones}" SelectedItem="{Binding SelectedTimeZone,Mode=TwoWay}">
-
- </touch:TouchComboBox>
- </StackPanel>
- </DockPanel>
- </StackPanel>
- </touch:TouchExpander>
-
- <!--TECHNICIAN-->
- <touch:TouchExpander Visibility="{Binding ApplicationManager.IsInTechnicianMode,Converter={StaticResource BooleanToVisibilityConverter}}" Margin="0 20 0 0" Header="Advanced" IsExpanded="True" FontSize="{StaticResource TangoExpanderHeaderFontSize}">
- <StackPanel Margin="10 30 10 10">
-
- <DockPanel TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Embedded COM Port</TextBlock>
- <touch:TouchTextBox KeyboardContainer="{Binding ElementName=Container}" Text="{Binding Settings.EmbeddedComPort}" Margin="0 0 100 0" DockPanel.Dock="Right" HorizontalAlignment="Right" Width="90"></touch:TouchTextBox>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Emergency COM Port</TextBlock>
- <touch:TouchTextBox KeyboardContainer="{Binding ElementName=Container}" Text="{Binding Settings.EmergencyComPort}" Margin="0 0 100 0" DockPanel.Dock="Right" HorizontalAlignment="Right" Width="90"></touch:TouchTextBox>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Enable Emergency Screen</TextBlock>
- <touch:TouchToggleSlider IsChecked="{Binding Settings.EnableEmergencyNotifications}" Margin="0 0 100 0" DockPanel.Dock="Right" Style="{StaticResource TangoToggleButtonGrayAccent}" HorizontalAlignment="Right" Width="90"></touch:TouchToggleSlider>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Enable Embedded Debug Logs</TextBlock>
- <touch:TouchToggleSlider IsChecked="{Binding Settings.EnableEmbeddedDebugLogs}" Margin="0 0 100 0" DockPanel.Dock="Right" Style="{StaticResource TangoToggleButtonGrayAccent}" HorizontalAlignment="Right" Width="90"></touch:TouchToggleSlider>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Enable Automatic Thread Loading Support</TextBlock>
- <touch:TouchToggleSlider IsChecked="{Binding Settings.EnableAutomaticThreadLoading}" Margin="0 0 100 0" DockPanel.Dock="Right" Style="{StaticResource TangoToggleButtonGrayAccent}" HorizontalAlignment="Right" Width="90"></touch:TouchToggleSlider>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Display PowerUp Screen</TextBlock>
- <touch:TouchToggleSlider IsChecked="{Binding Settings.DisplayPowerUpScreen}" Margin="0 0 100 0" DockPanel.Dock="Right" Style="{StaticResource TangoToggleButtonGrayAccent}" HorizontalAlignment="Right" Width="90"></touch:TouchToggleSlider>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Enable Job Liquid Quantity Validation</TextBlock>
- <touch:TouchToggleSlider IsChecked="{Binding Settings.EnableJobLiquidQuantityValidation}" Margin="0 0 100 0" DockPanel.Dock="Right" Style="{StaticResource TangoToggleButtonGrayAccent}" HorizontalAlignment="Right" Width="90"></touch:TouchToggleSlider>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Always Start in Technician Mode</TextBlock>
- <touch:TouchToggleSlider IsChecked="{Binding Settings.EnableTechnicianModeByDefault}" Margin="0 0 100 0" DockPanel.Dock="Right" Style="{StaticResource TangoToggleButtonGrayAccent}" HorizontalAlignment="Right" Width="90"></touch:TouchToggleSlider>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Enable External Bridge SignalR</TextBlock>
- <touch:TouchToggleSlider IsChecked="{Binding Settings.EnableExternalBridgeSignalR}" Margin="0 0 100 0" DockPanel.Dock="Right" Style="{StaticResource TangoToggleButtonGrayAccent}" HorizontalAlignment="Right" Width="90"></touch:TouchToggleSlider>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Auto Update Check Interval Minutes</TextBlock>
- <touch:TouchNumericTextBox Minimum="1" Maximum="120" KeyboardContainer="{Binding ElementName=Container}" Value="{Binding Settings.AutoUpdateCheckInterval,Converter={StaticResource TimeSpanToMinutesConverter}}" Margin="0 0 100 0" DockPanel.Dock="Right" HorizontalAlignment="Right" Width="90"></touch:TouchNumericTextBox>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Bypass Internet Connectivity Checks</TextBlock>
- <touch:TouchToggleSlider IsChecked="{Binding Settings.BypassInternetConnectivityCheck}" Margin="0 0 100 0" DockPanel.Dock="Right" Style="{StaticResource TangoToggleButtonGrayAccent}" HorizontalAlignment="Right" Width="90"></touch:TouchToggleSlider>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Gradient Resolution CM</TextBlock>
- <touch:TouchNumericTextBox Minimum="10" Maximum="500" KeyboardContainer="{Binding ElementName=Container}" Value="{Binding Settings.GradientGenerationResolution}" Margin="0 0 100 0" DockPanel.Dock="Right" HorizontalAlignment="Right" Width="90"></touch:TouchNumericTextBox>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Enable Insights</TextBlock>
- <touch:TouchToggleSlider IsChecked="{Binding Settings.InsightsEnabled}" Margin="0 0 100 0" DockPanel.Dock="Right" Style="{StaticResource TangoToggleButtonGrayAccent}" HorizontalAlignment="Right" Width="90"></touch:TouchToggleSlider>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Insights Sampling Interval (sec)</TextBlock>
- <touch:TouchNumericTextBox Minimum="1" Maximum="300" KeyboardContainer="{Binding ElementName=Container}" Value="{Binding Settings.InsightsSamplingInterval,Converter={StaticResource TimeSpanToSecondsConverter}}" Margin="0 0 100 0" DockPanel.Dock="Right" HorizontalAlignment="Right" Width="90"></touch:TouchNumericTextBox>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Insights Storage Cleanup Interval (min)</TextBlock>
- <touch:TouchNumericTextBox Minimum="1" Maximum="120" KeyboardContainer="{Binding ElementName=Container}" Value="{Binding Settings.InsightsStorageCleanupInterval,Converter={StaticResource TimeSpanToMinutesConverter}}" Margin="0 0 100 0" DockPanel.Dock="Right" HorizontalAlignment="Right" Width="90"></touch:TouchNumericTextBox>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Insights Max Storage Duration (days)</TextBlock>
- <touch:TouchNumericTextBox Minimum="1" Maximum="120" KeyboardContainer="{Binding ElementName=Container}" Value="{Binding Settings.InsightsMaxStorageDuration,Converter={StaticResource TimeSpanToDaysConverter}}" Margin="0 0 100 0" DockPanel.Dock="Right" HorizontalAlignment="Right" Width="90"></touch:TouchNumericTextBox>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0" TextElement.FontSize="{StaticResource TangoDefaultFontSize}">
- <TextBlock VerticalAlignment="Center">Enable UWF (Disk Protection)</TextBlock>
- <touch:TouchToggleSlider IsChecked="{Binding EnableUWF}" Margin="0 0 100 0" DockPanel.Dock="Right" Style="{StaticResource TangoToggleButtonGrayAccent}" HorizontalAlignment="Right" Width="90"></touch:TouchToggleSlider>
- </DockPanel>
-
- <DockPanel Margin="0 20 0 0">
- <touch:TouchIcon VerticalAlignment="Top" Icon="InformationOutline" Foreground="{StaticResource TangoGrayTextBrush}"></touch:TouchIcon>
- <TextBlock Margin="10 0 0 0" VerticalAlignment="Top" TextWrapping="Wrap" FontSize="{StaticResource TangoSmallFontSize}" Foreground="{StaticResource TangoGrayTextBrush}">
- Please restart the application for advanced settings to take effect.
- </TextBlock>
- </DockPanel>
- </StackPanel>
- </touch:TouchExpander>
</StackPanel>
</touch:LightTouchScrollViewer>
</Grid>