diff options
Diffstat (limited to 'Software/Visual_Studio/PPC')
7 files changed, 21 insertions, 24 deletions
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/ViewModels/MaintenanceViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/ViewModels/MaintenanceViewVM.cs index 1890fdab7..cd646ce02 100644 --- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/ViewModels/MaintenanceViewVM.cs +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/ViewModels/MaintenanceViewVM.cs @@ -190,7 +190,7 @@ namespace Tango.PPC.Maintenance.ViewModels UpdateMidTankLevels(status); OverallTemperature.Temperature = status.OverallTemperature; SpoolState = status.SpoolState; - _isInkAutoFillingEnabled = status.AutoInkFillingDisabled; + _isInkAutoFillingEnabled = status.AutoInkFillingEnabled; RaisePropertyChanged(nameof(IsInkAutoFillingEnabled)); InvalidateRelayCommands(); } diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/MaintenanceView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/MaintenanceView.xaml index 4f93f9b31..a77ec5901 100644 --- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/MaintenanceView.xaml +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/MaintenanceView.xaml @@ -261,7 +261,7 @@ <touch:TouchButton Margin="20" CornerRadius="25" Height="50" FontSize="18" Style="{StaticResource TangoHollowButton}" Command="{Binding ViewBitResultsCommand}">VIEW BIT RESULTS</touch:TouchButton> - <touch:TouchToggleButton EnableDropShadow="False" Background="Transparent" BorderThickness="2" BorderBrush="{StaticResource TangoPrimaryAccentBrush}" Margin="20" CornerRadius="25" Height="50" FontSize="18" IsChecked="{Binding IsInkAutoFillingDisabled}" IsEnabled="{Binding MachineProvider.IsConnected}" Content="DISABLE AUTO INK FILLING" CheckedContent="ENABLE AUTO INK FILLING" Foreground="{StaticResource TangoPrimaryAccentBrush}"></touch:TouchToggleButton> + <touch:TouchToggleButton EnableDropShadow="False" Background="Transparent" BorderThickness="2" BorderBrush="{StaticResource TangoPrimaryAccentBrush}" Margin="20" CornerRadius="25" Height="50" FontSize="18" IsChecked="{Binding IsInkAutoFillingEnabled}" IsEnabled="{Binding MachineProvider.IsConnected}" Content="ENABLE AUTO INK FILLING" CheckedContent="DISABLE AUTO INK FILLING" Foreground="{StaticResource TangoPrimaryAccentBrush}"></touch:TouchToggleButton> </UniformGrid> </StackPanel> diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/Dialogs/InsufficientLiquidQuantityView.xaml b/Software/Visual_Studio/PPC/Tango.PPC.UI/Dialogs/InsufficientLiquidQuantityView.xaml index d2fe31387..d9ec6d1c2 100644 --- a/Software/Visual_Studio/PPC/Tango.PPC.UI/Dialogs/InsufficientLiquidQuantityView.xaml +++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/Dialogs/InsufficientLiquidQuantityView.xaml @@ -12,9 +12,9 @@ <Grid DockPanel.Dock="Bottom"> <touch:TouchButton HorizontalAlignment="Right" CornerRadius="25" Command="{Binding OKCommand}" Style="{StaticResource TangoHollowButton}" Width="150" Height="50" VerticalAlignment="Bottom">CLOSE</touch:TouchButton> - <StackPanel HorizontalAlignment="Left" Visibility="{Binding IsAutoInkFillingDisabled,Converter={StaticResource BooleanToVisibilityConverter}}"> + <StackPanel HorizontalAlignment="Left" Visibility="{Binding IsAutoInkFillingEnabled,Converter={StaticResource BooleanToVisibilityInverseConverter}}"> <TextBlock HorizontalAlignment="Center" Foreground="{StaticResource TangoErrorBrush}">Auto ink filling is disabled</TextBlock> - <touch:TouchButton CornerRadius="25" Margin="0 5 0 0" Command="{Binding EnableAutoInkFillingCommand}" Style="{StaticResource TangoHollowButton}" Width="300" Height="50" VerticalAlignment="Bottom">ENABLE AUTO INK FILLING</touch:TouchButton> + <touch:TouchButton CornerRadius="25" Margin="0 5 0 0" Command="{Binding StartAutoInkFillingCommand}" Style="{StaticResource TangoHollowButton}" Width="300" Height="50" VerticalAlignment="Bottom">START INK FILLING</touch:TouchButton> </StackPanel> </Grid> <StackPanel DockPanel.Dock="Top"> diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/Dialogs/InsufficientLiquidQuantityViewVM.cs b/Software/Visual_Studio/PPC/Tango.PPC.UI/Dialogs/InsufficientLiquidQuantityViewVM.cs index 6d4c90e21..20f1fc18a 100644 --- a/Software/Visual_Studio/PPC/Tango.PPC.UI/Dialogs/InsufficientLiquidQuantityViewVM.cs +++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/Dialogs/InsufficientLiquidQuantityViewVM.cs @@ -13,22 +13,22 @@ namespace Tango.PPC.UI.Dialogs { public InsufficientLiquidQuantityException Exception { get; set; } - public bool IsAutoInkFillingDisabled { get; set; } + public bool IsAutoInkFillingEnabled { get; set; } - public bool EnableAutoInkFillingOnExit { get; set; } + public bool StartAutoInkFillingOnExit { get; set; } - public RelayCommand EnableAutoInkFillingCommand { get; set; } + public RelayCommand StartAutoInkFillingCommand { get; set; } - public InsufficientLiquidQuantityViewVM(InsufficientLiquidQuantityException ex,bool isAutoInkFillingDisabled) + public InsufficientLiquidQuantityViewVM(InsufficientLiquidQuantityException ex,bool isAutoInkFillingEnabled) { Exception = ex; - IsAutoInkFillingDisabled = isAutoInkFillingDisabled; - EnableAutoInkFillingCommand = new RelayCommand(EnableAutoInkFilling); + IsAutoInkFillingEnabled = isAutoInkFillingEnabled; + StartAutoInkFillingCommand = new RelayCommand(StartAutoInkFilling); } - private void EnableAutoInkFilling() + private void StartAutoInkFilling() { - EnableAutoInkFillingOnExit = true; + StartAutoInkFillingOnExit = true; Accept(); } } diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/Printing/DefaultPrintingManager.cs b/Software/Visual_Studio/PPC/Tango.PPC.UI/Printing/DefaultPrintingManager.cs index 9856faf3d..938d99451 100644 --- a/Software/Visual_Studio/PPC/Tango.PPC.UI/Printing/DefaultPrintingManager.cs +++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/Printing/DefaultPrintingManager.cs @@ -104,22 +104,19 @@ namespace Tango.PPC.UI.Printing _notificationProvider.ReleaseGlobalBusyMessage(); LogManager.Log(ex); - var vm = await _notificationProvider.ShowDialog(new InsufficientLiquidQuantityViewVM(ex, _machineProvider.MachineOperator.MachineStatus.AutoInkFillingDisabled)); + var vm = await _notificationProvider.ShowDialog(new InsufficientLiquidQuantityViewVM(ex, _machineProvider.MachineOperator.MachineStatus.AutoInkFillingEnabled)); - if (vm.EnableAutoInkFillingOnExit) + if (vm.StartAutoInkFillingOnExit) { try { - _notificationProvider.SetGlobalBusyMessage("Enabling auto ink filling..."); - await _machineProvider.MachineOperator.SendRequest<SetInkAutoFillingModeRequest, SetInkAutoFillingModeResponse>(new SetInkAutoFillingModeRequest() - { - Disabled = false - }); + _notificationProvider.SetGlobalBusyMessage("Starting ink filling..."); + await _machineProvider.MachineOperator.SendRequest<InitiateInkFillingRequest, InitiateInkFillingResponse>(new InitiateInkFillingRequest()); } catch (Exception exx) { - LogManager.Log(exx, "Error enabling ink filling."); - await _notificationProvider.ShowError($"Error enabling auto ink filling.\n{ex.Message}"); + LogManager.Log(exx, "Error starting ink filling."); + await _notificationProvider.ShowError($"Error starting ink filling.\n{ex.Message}"); } finally { diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/LayoutView.xaml b/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/LayoutView.xaml index ff35fb059..1417c79f3 100644 --- a/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/LayoutView.xaml +++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/LayoutView.xaml @@ -291,7 +291,7 @@ <Style TargetType="Grid"> <Setter Property="Visibility" Value="Hidden"></Setter> <Style.Triggers> - <DataTrigger Binding="{Binding MachineProvider.MachineOperator.MachineStatus.AutoInkFillingDisabled}" Value="True"> + <DataTrigger Binding="{Binding MachineProvider.MachineOperator.MachineStatus.AutoInkFillingEnabled}" Value="True"> <Setter Property="Visibility" Value="Visible"></Setter> </DataTrigger> <DataTrigger Binding="{Binding MachineProvider.MachineOperator.IsConnected}" Value="False"> @@ -300,7 +300,7 @@ </Style.Triggers> </Style> </Grid.Style> - <touch:TouchIcon Icon="LightningBoltOutline" Foreground="#151515" Width="24" Height="24" HorizontalAlignment="Right" VerticalAlignment="Top" Margin="0 3 -35 0"></touch:TouchIcon> + <touch:TouchIcon Icon="InvertColors" Foreground="#151515" Width="18" Height="18" HorizontalAlignment="Right" VerticalAlignment="Top" Margin="0 6 -30 0"></touch:TouchIcon> </Grid> </Grid> diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/app.manifest b/Software/Visual_Studio/PPC/Tango.PPC.UI/app.manifest index d72e75011..efc5f8179 100644 --- a/Software/Visual_Studio/PPC/Tango.PPC.UI/app.manifest +++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/app.manifest @@ -16,7 +16,7 @@ Remove this element if your application requires this virtualization for backwards compatibility. --> - <requestedExecutionLevel level="requireAdministrator" uiAccess="false" /> + <!--<requestedExecutionLevel level="requireAdministrator" uiAccess="false" />--> </requestedPrivileges> </security> </trustInfo> |
