diff options
| author | Roy <Roy.mail.net@gmail.com> | 2023-09-03 16:18:55 +0300 |
|---|---|---|
| committer | Roy <Roy.mail.net@gmail.com> | 2023-09-03 16:18:55 +0300 |
| commit | c66acc359b311ecc940f3c4e74bd9e21dc0bfd51 (patch) | |
| tree | 8869b9d48fbad776c94df401680afc43fc350e69 /Software/Visual_Studio/FSE | |
| parent | 6cdea71fa07d092139697d9c67651dade37aed96 (diff) | |
| parent | b271fe1c21172ed22a34b987a2cb9457b39ce8a3 (diff) | |
| download | Tango-c66acc359b311ecc940f3c4e74bd9e21dc0bfd51.tar.gz Tango-c66acc359b311ecc940f3c4e74bd9e21dc0bfd51.zip | |
Merged Eureka Branch !!!
Diffstat (limited to 'Software/Visual_Studio/FSE')
60 files changed, 979 insertions, 258 deletions
diff --git a/Software/Visual_Studio/FSE/Modules/Tango.FSE.MachineConfiguration/Views/MachineView.xaml b/Software/Visual_Studio/FSE/Modules/Tango.FSE.MachineConfiguration/Views/MachineView.xaml index d33966e18..3de00198c 100644 --- a/Software/Visual_Studio/FSE/Modules/Tango.FSE.MachineConfiguration/Views/MachineView.xaml +++ b/Software/Visual_Studio/FSE/Modules/Tango.FSE.MachineConfiguration/Views/MachineView.xaml @@ -27,7 +27,7 @@ <DockPanel> <StackPanel Orientation="Horizontal" DockPanel.Dock="Top" HorizontalAlignment="Left"> - <Image Source="{StaticResource FSE_Machine_Full}" Width="100" Stretch="Uniform" RenderOptions.BitmapScalingMode="Fant" /> + <commonControls:MachineIconFull Height="80" DataContext="{Binding EditingComposition.Machine}" /> <StackPanel Margin="5 0 0 0"> <TextBlock Text="{Binding EditingComposition.Machine.SerialNumber,FallbackValue='101010'}" FontSize="{StaticResource FSE_ModuleHeaderFontSize}"></TextBlock> <TextBlock Text="{Binding EditingComposition.Machine.Organization.Name,FallbackValue='Organization'}" FontSize="{StaticResource FSE_LargerFontSize}" Foreground="{StaticResource FSE_GrayBrush}"></TextBlock> diff --git a/Software/Visual_Studio/FSE/Modules/Tango.FSE.MachineConfiguration/Views/SelectionView.xaml b/Software/Visual_Studio/FSE/Modules/Tango.FSE.MachineConfiguration/Views/SelectionView.xaml index a2aa7240b..ca6d3ca4c 100644 --- a/Software/Visual_Studio/FSE/Modules/Tango.FSE.MachineConfiguration/Views/SelectionView.xaml +++ b/Software/Visual_Studio/FSE/Modules/Tango.FSE.MachineConfiguration/Views/SelectionView.xaml @@ -4,6 +4,7 @@ xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:local="clr-namespace:Tango.FSE.MachineConfiguration.Views" + xmlns:controls="clr-namespace:Tango.FSE.Common.Controls;assembly=Tango.FSE.Common" xmlns:material="http://materialdesigninxaml.net/winfx/xaml/themes" xmlns:global="clr-namespace:Tango.FSE.MachineConfiguration" xmlns:autoComplete="clr-namespace:Tango.AutoComplete.Editors;assembly=Tango.AutoComplete" @@ -28,7 +29,7 @@ <autoComplete:AutoCompleteTextBox.SelectedItemTemplate> <DataTemplate> <DockPanel VerticalAlignment="Center"> - <Image RenderOptions.BitmapScalingMode="Fant" Source="{StaticResource FSE_Machine_Small}" Width="24" /> + <controls:MachineIcon RenderOptions.BitmapScalingMode="Fant" Height="24" /> <StackPanel VerticalAlignment="Center" Margin="10 0 0 0" Orientation="Horizontal"> <TextBlock Text="{Binding SerialNumber}" FontSize="{StaticResource FSE_SmallFontSize}"></TextBlock> <TextBlock Margin="10 0 0 0" FontSize="{StaticResource FSE_SmallFontSize}" Foreground="{StaticResource FSE_GrayBrush}" Text="{Binding Name}"></TextBlock> @@ -39,7 +40,7 @@ <autoComplete:AutoCompleteTextBox.ItemTemplate> <DataTemplate> <DockPanel VerticalAlignment="Center"> - <Image RenderOptions.BitmapScalingMode="Fant" Source="{StaticResource FSE_Machine_Small}" Width="32" /> + <controls:MachineIcon Height="32" /> <StackPanel Margin="5 0 0 0"> <TextBlock Text="{Binding SerialNumber}"></TextBlock> <TextBlock Margin="0 5 0 0" FontSize="{StaticResource FSE_SmallerFontSize}" Foreground="{StaticResource FSE_GrayBrush}" Text="{Binding Name}"></TextBlock> diff --git a/Software/Visual_Studio/FSE/Modules/Tango.FSE.PPCConsole/Controls/RemoteDesktopControl.xaml b/Software/Visual_Studio/FSE/Modules/Tango.FSE.PPCConsole/Controls/RemoteDesktopControl.xaml index 4e6959e5b..da3cb101c 100644 --- a/Software/Visual_Studio/FSE/Modules/Tango.FSE.PPCConsole/Controls/RemoteDesktopControl.xaml +++ b/Software/Visual_Studio/FSE/Modules/Tango.FSE.PPCConsole/Controls/RemoteDesktopControl.xaml @@ -32,7 +32,19 @@ <Border.Background> <ImageBrush ImageSource="{StaticResource FSE_PPC_Back}" /> </Border.Background> - <Border Width="{Binding RelativeSource={RelativeSource Self},Path=ActualHeight,Converter={StaticResource MathOperatorConverter},ConverterParameter='/1.6',FallbackValue=500,TargetNullValue=500}"> + <Border> + <Border.Style> + <Style TargetType="Border"> + <Setter Property="Width" Value="{Binding RelativeSource={RelativeSource Self},Path=ActualHeight,Converter={StaticResource MathOperatorConverter},ConverterParameter='/1.6',FallbackValue=500,TargetNullValue=500}"></Setter> + <Setter Property="Height" Value="Auto"></Setter> + <Style.Triggers> + <DataTrigger Binding="{Binding MachineProvider.MachineOperator.MachineType}" Value="Eureka"> + <Setter Property="Width" Value="Auto"></Setter> + <Setter Property="Height" Value="{Binding RelativeSource={RelativeSource Self},Path=ActualWidth,Converter={StaticResource MathOperatorConverter},ConverterParameter='/1.7',FallbackValue=500,TargetNullValue=500}"></Setter> + </DataTrigger> + </Style.Triggers> + </Style> + </Border.Style> <Grid> <Image x:Name="img" FocusVisualStyle="{x:Null}" Focusable="True" Source="{Binding Source}" RenderOptions.BitmapScalingMode="Fant" Stretch="Fill" Visibility="{Binding RemoteDesktopProvider.InSession,Converter={StaticResource BooleanToVisibilityConverter}}"></Image> <Rectangle x:Name="rectSnapshot" Fill="White" IsHitTestVisible="False" Opacity="0"></Rectangle> diff --git a/Software/Visual_Studio/FSE/Modules/Tango.FSE.PPCConsole/Views/RemoteDesktopView.xaml b/Software/Visual_Studio/FSE/Modules/Tango.FSE.PPCConsole/Views/RemoteDesktopView.xaml index 833e3bd44..1560b759d 100644 --- a/Software/Visual_Studio/FSE/Modules/Tango.FSE.PPCConsole/Views/RemoteDesktopView.xaml +++ b/Software/Visual_Studio/FSE/Modules/Tango.FSE.PPCConsole/Views/RemoteDesktopView.xaml @@ -16,18 +16,42 @@ <Grid> <DockPanel IsEnabled="{Binding IsFree}"> <Grid DockPanel.Dock="Right" IsEnabled="{Binding MachineProvider.IsPPCAvailable}"> + <Grid.Style> + <Style TargetType="Grid"> + <Setter Property="VerticalAlignment" Value="Stretch"></Setter> + <Setter Property="Width" Value="Auto"></Setter> + <Style.Triggers> + <DataTrigger Binding="{Binding MachineProvider.MachineOperator.MachineType}" Value="Eureka"> + <Setter Property="VerticalAlignment" Value="Top"></Setter> + <Setter Property="Width" Value="490"></Setter> + </DataTrigger> + </Style.Triggers> + </Style> + </Grid.Style> <Border> - <localControls:RemoteDesktopControl - x:Name="remoteDesktopControl" - win:WindowsManagerHelper.MinWidth="400" - win:WindowsManagerHelper.MinHeight="640" - win:WindowsManagerHelper.StartWidth="400" - win:WindowsManagerHelper.StartHeight="640" + <localControls:RemoteDesktopControl x:Name="remoteDesktopControl" win:WindowsManagerHelper.LockAspectRatio="True" win:WindowsManagerHelper.WindowTitle="{Binding MachineProvider.Machine.SerialNumber}" win:WindowsManagerHelper.DisableMaximize="True" win:WindowsManagerHelper.PreservePlaceHolder="True" - win:WindowsManagerHelper.DisableResolutionServiceInjection="True"/> + win:WindowsManagerHelper.DisableResolutionServiceInjection="True"> + <localControls:RemoteDesktopControl.Style> + <Style TargetType="localControls:RemoteDesktopControl"> + <Setter Property="win:WindowsManagerHelper.MinWidth" Value="400"/> + <Setter Property="win:WindowsManagerHelper.MinWidth" Value="640"/> + <Setter Property="win:WindowsManagerHelper.StartWidth" Value="400"/> + <Setter Property="win:WindowsManagerHelper.StartHeight" Value="640"/> + <Style.Triggers> + <DataTrigger Binding="{Binding MachineProvider.MachineOperator.MachineType}" Value="Eureka"> + <Setter Property="win:WindowsManagerHelper.MinWidth" Value="640"/> + <Setter Property="win:WindowsManagerHelper.MinHeight" Value="440"/> + <Setter Property="win:WindowsManagerHelper.StartWidth" Value="640"/> + <Setter Property="win:WindowsManagerHelper.StartHeight" Value="440"/> + </DataTrigger> + </Style.Triggers> + </Style> + </localControls:RemoteDesktopControl.Style> + </localControls:RemoteDesktopControl> </Border> </Grid> diff --git a/Software/Visual_Studio/FSE/Modules/Tango.FSE.Procedures.Documentation/Help/proc-doc.chm b/Software/Visual_Studio/FSE/Modules/Tango.FSE.Procedures.Documentation/Help/proc-doc.chm Binary files differindex eeeb72237..b6bc6d4cd 100644 --- a/Software/Visual_Studio/FSE/Modules/Tango.FSE.Procedures.Documentation/Help/proc-doc.chm +++ b/Software/Visual_Studio/FSE/Modules/Tango.FSE.Procedures.Documentation/Help/proc-doc.chm diff --git a/Software/Visual_Studio/FSE/Modules/Tango.FSE.Statistics/Models/StopModel.cs b/Software/Visual_Studio/FSE/Modules/Tango.FSE.Statistics/Models/StopModel.cs index 24ddc80bf..3d616f957 100644 --- a/Software/Visual_Studio/FSE/Modules/Tango.FSE.Statistics/Models/StopModel.cs +++ b/Software/Visual_Studio/FSE/Modules/Tango.FSE.Statistics/Models/StopModel.cs @@ -29,6 +29,7 @@ namespace Tango.FSE.Statistics.Models public JobRunExtendedInfo ExtendedInfo { get; set; } public bool IsAdvancedMode { get; set; } public VectorFineTuningRunModel FineTuningModel { get; set; } + public bool IsEureka { get; set; } public bool IsFineTuning { @@ -163,7 +164,18 @@ namespace Tango.FSE.Statistics.Models public String LogicalLength { - get { return JobRun.NumberOfUnits > 1 ? $"{JobRun.JobLogicalLength} x{JobRun.NumberOfUnits}" : JobRun.JobLogicalLength.ToString(); } + get { var length = IsEureka ? JobRun.JobLogicalLength * 4 : JobRun.JobLogicalLength; + return JobRun.NumberOfUnits > 1 ? $"{length} x{JobRun.NumberOfUnits}" : length.ToString(); } + } + + public double JobLength + { + get { return IsEureka ? JobRun.JobLength * 4 : JobRun.JobLength; } + } + + public double EndPosition + { + get { return IsEureka ? JobRun.EndPosition * 4 : JobRun.EndPosition; } } public String FineTuningMeasured diff --git a/Software/Visual_Studio/FSE/Modules/Tango.FSE.Statistics/ViewModels/MainViewVM.cs b/Software/Visual_Studio/FSE/Modules/Tango.FSE.Statistics/ViewModels/MainViewVM.cs index d77b0b5a1..ae4444f06 100644 --- a/Software/Visual_Studio/FSE/Modules/Tango.FSE.Statistics/ViewModels/MainViewVM.cs +++ b/Software/Visual_Studio/FSE/Modules/Tango.FSE.Statistics/ViewModels/MainViewVM.cs @@ -422,6 +422,7 @@ namespace Tango.FSE.Statistics.ViewModels stop.ThreadName = rmlName; stop.IsAdvancedMode = !BuildProvider.IsTwineRSM && CurrentUser.HasRole(Roles.FSEAdvancedTechnician); stop.FineTuningModel = fineTuningModel; + stop.IsEureka = MachineProvider.MachineOperator.MachineType == MachineTypes.Eureka; if (fineTuningModel != null) { @@ -735,11 +736,11 @@ namespace Tango.FSE.Statistics.ViewModels model.JobName = stop.JobRun.JobName; model.JobKind = ((JobDesignations)stop.JobRun.JobDesignation).ToDescription(); model.Thread = stop.ThreadName; - model.Length = ((int)stop.JobRun.JobLogicalLength).ToString(); + model.Length = stop.LogicalLength; model.NumberOfUnits = stop.JobRun.NumberOfUnits.ToString(); model.StartTime = stop.JobRun.StartDate.ToLocalTime().ToString(); model.Duration = stop.Duration.ToStringUnlimitedHours(); - model.EndPosition = stop.JobRun.EndPosition.ToString(); + model.EndPosition = stop.EndPosition.ToString(); model.Status = ((JobRunStatus)stop.JobRun.Status).ToString(); model.SegmentIndex = stop.SegmentIndex.ToString(); model.Offset = stop.StartMeters.ToString(); diff --git a/Software/Visual_Studio/FSE/Modules/Tango.FSE.Statistics/Views/MainView.xaml b/Software/Visual_Studio/FSE/Modules/Tango.FSE.Statistics/Views/MainView.xaml index 5f0ceaa5a..88b460ab1 100644 --- a/Software/Visual_Studio/FSE/Modules/Tango.FSE.Statistics/Views/MainView.xaml +++ b/Software/Visual_Studio/FSE/Modules/Tango.FSE.Statistics/Views/MainView.xaml @@ -138,13 +138,13 @@ <TextBlock> <Run>Actual Length:</Run> <LineBreak/> - <Run Text="{Binding Items[0].Items[0].JobRun.JobLength}"></Run> + <Run Text="{Binding Items[0].Items[0].JobLength, Mode=OneWay}"></Run> </TextBlock> </TextBlock.ToolTip> </TextBlock> <TextBlock Text="{Binding Items[0].Items[0].JobRun.StartDate,Converter={StaticResource DateTimeUTCToShortDateTimeConverter}}" VerticalAlignment="Center" Width="120"></TextBlock> <TextBlock Text="{Binding Items[0].Items[0].Duration,Mode=OneWay,Converter={StaticResource TotalDyeTimeConverter}}" VerticalAlignment="Center" Width="100"></TextBlock> - <TextBlock Text="{Binding Items[0].Items[0].JobRun.EndPosition,StringFormat=N1}" VerticalAlignment="Center" Width="80"></TextBlock> + <TextBlock Text="{Binding Items[0].Items[0].EndPosition,StringFormat=N1}" VerticalAlignment="Center" Width="80"></TextBlock> </StackPanel> <Grid Visibility="{Binding IsAdvancedMode,Converter={StaticResource BooleanToVisibilityConverter}}" DataContext="{Binding Items[0].Items[0]}" Width="250" Margin="0 0 50 5" HorizontalAlignment="Right" VerticalAlignment="Bottom"> diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Connection/MachineConnectionTypes.cs b/Software/Visual_Studio/FSE/Tango.FSE.Common/Connection/MachineConnectionTypes.cs index ef233dda8..5b585533e 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.Common/Connection/MachineConnectionTypes.cs +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Connection/MachineConnectionTypes.cs @@ -17,6 +17,10 @@ namespace Tango.FSE.Common.Connection /// </summary> USB, /// <summary> + /// Local TCP connection. + /// </summary> + TCP, + /// <summary> /// Local area network. /// </summary> Wifi, diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/ConnectedMachineIcon.xaml b/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/ConnectedMachineIcon.xaml index f6be93ec9..98d9dc13d 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/ConnectedMachineIcon.xaml +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/ConnectedMachineIcon.xaml @@ -9,24 +9,6 @@ mc:Ignorable="d" d:DesignHeight="50" d:DesignWidth="50" Height="50"> <Grid> - <ContentControl Content="{Binding}" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch"> - <ContentControl.Resources> - <DataTemplate DataType="{x:Type integration:ExternalBridgeSignalRClient}"> - <ContentControl Style="{StaticResource FSE_SignalRMachineIcon}" /> - </DataTemplate> - - <DataTemplate DataType="{x:Type integration:ExternalBridgeTcpClient}"> - <ContentControl Style="{StaticResource FSE_WifiMachineIcon}" /> - </DataTemplate> - - <DataTemplate DataType="{x:Type integration:ExternalBridgeUsbClient}"> - <ContentControl Style="{StaticResource FSE_UsbMachineIcon}" /> - </DataTemplate> - - <DataTemplate DataType="{x:Type emulations:EmulatorExternalBridge}"> - <ContentControl Style="{StaticResource FSE_EmulatorMachineIcon}"/> - </DataTemplate> - </ContentControl.Resources> - </ContentControl> + <local:MachineConnectionIcon ExternalBridgeClient="{Binding}" /> </Grid> </UserControl> diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/MachineConnectionIcon.cs b/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/MachineConnectionIcon.cs new file mode 100644 index 000000000..d739ac6e5 --- /dev/null +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/MachineConnectionIcon.cs @@ -0,0 +1,83 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows; +using System.Windows.Controls; +using System.Windows.Data; +using System.Windows.Documents; +using System.Windows.Input; +using System.Windows.Media; +using System.Windows.Media.Imaging; +using System.Windows.Navigation; +using System.Windows.Shapes; +using Tango.BL.Enumerations; +using Tango.Emulations.ExternalBridge; +using Tango.FSE.Common.Connection; +using Tango.Integration.ExternalBridge; + +namespace Tango.FSE.Common.Controls +{ + public class MachineConnectionIcon : Control + { + public MachineTypes MachineType + { + get { return (MachineTypes)GetValue(MachineTypeProperty); } + set { SetValue(MachineTypeProperty, value); } + } + public static readonly DependencyProperty MachineTypeProperty = + DependencyProperty.Register("MachineType", typeof(MachineTypes), typeof(MachineConnectionIcon), new PropertyMetadata(MachineTypes.TS1800)); + + public IExternalBridgeClient ExternalBridgeClient + { + get { return (IExternalBridgeClient)GetValue(ExternalBridgeClientProperty); } + set { SetValue(ExternalBridgeClientProperty, value); } + } + public static readonly DependencyProperty ExternalBridgeClientProperty = + DependencyProperty.Register("ExternalBridgeClient", typeof(IExternalBridgeClient), typeof(MachineConnectionIcon), new PropertyMetadata((d, e) => (d as MachineConnectionIcon).OnExternalBridgeClientChanged())); + + public MachineConnectionTypes ExternalBridgeClientType + { + get { return (MachineConnectionTypes)GetValue(ExternalBridgeClientTypeProperty); } + set { SetValue(ExternalBridgeClientTypeProperty, value); } + } + public static readonly DependencyProperty ExternalBridgeClientTypeProperty = + DependencyProperty.Register("ExternalBridgeClientType", typeof(MachineConnectionTypes), typeof(MachineConnectionIcon), new PropertyMetadata(MachineConnectionTypes.USB)); + + private void OnExternalBridgeClientChanged() + { + if (ExternalBridgeClient != null) + { + if (ExternalBridgeClient.GetType() == typeof(ExternalBridgeUsbClient)) + { + ExternalBridgeClientType = MachineConnectionTypes.USB; + } + else if (ExternalBridgeClient.GetType() == typeof(ExternalBridgeTcpFirmwareClient)) + { + ExternalBridgeClientType = MachineConnectionTypes.TCP; + MachineType = MachineTypes.Eureka; + } + else if (ExternalBridgeClient.GetType() == typeof(ExternalBridgeTcpClient)) + { + ExternalBridgeClientType = MachineConnectionTypes.Wifi; + MachineType = ExternalBridgeClient.MachineType; + } + else if (ExternalBridgeClient.GetType() == typeof(ExternalBridgeSignalRClient)) + { + ExternalBridgeClientType = MachineConnectionTypes.SignalR; + MachineType = ExternalBridgeClient.MachineType; + } + else if (ExternalBridgeClient.GetType() == typeof(EmulatorExternalBridge)) + { + ExternalBridgeClientType = MachineConnectionTypes.Emulator; + } + } + } + + static MachineConnectionIcon() + { + DefaultStyleKeyProperty.OverrideMetadata(typeof(MachineConnectionIcon), new FrameworkPropertyMetadata(typeof(MachineConnectionIcon))); + } + } +} diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/MachineConnectionIcon.xaml b/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/MachineConnectionIcon.xaml new file mode 100644 index 000000000..c402b2d21 --- /dev/null +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/MachineConnectionIcon.xaml @@ -0,0 +1,64 @@ +<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" + xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" + xmlns:material="http://materialdesigninxaml.net/winfx/xaml/themes" + xmlns:local="clr-namespace:Tango.FSE.Common.Controls"> + + <Style TargetType="{x:Type local:MachineConnectionIcon}"> + <Setter Property="Template"> + <Setter.Value> + <ControlTemplate TargetType="{x:Type local:MachineConnectionIcon}"> + <Border Background="{TemplateBinding Background}" + BorderBrush="{TemplateBinding BorderBrush}" + BorderThickness="{TemplateBinding BorderThickness}"> + <Grid DataContext="{Binding RelativeSource={RelativeSource Mode=FindAncestor, AncestorType=local:MachineConnectionIcon}}"> + <Image Margin="0 5 10 0" RenderOptions.BitmapScalingMode="Fant"> + <Image.Style> + <Style TargetType="Image"> + <Setter Property="Source" Value="../Images/Connections/ts1800.png"></Setter> + <Style.Triggers> + <DataTrigger Binding="{Binding MachineType}" Value="Eureka"> + <Setter Property="Source" Value="../Images/Connections/eureka.png"></Setter> + </DataTrigger> + </Style.Triggers> + </Style> + </Image.Style> + </Image> + + <material:PackIcon RenderOptions.BitmapScalingMode="Fant" Width="20" Height="20" VerticalAlignment="Top" HorizontalAlignment="Right" Margin="0 0 -1 0"> + <material:PackIcon.Style> + <Style TargetType="material:PackIcon"> + <Setter Property="Kind" Value="Usb"></Setter> + <Setter Property="Foreground" Value="{StaticResource FSE_UsbBrush}"></Setter> + <Style.Triggers> + <DataTrigger Binding="{Binding ExternalBridgeClientType}" Value="USB"> + <Setter Property="Kind" Value="Usb"></Setter> + <Setter Property="Foreground" Value="{StaticResource FSE_UsbBrush}"></Setter> + </DataTrigger> + <DataTrigger Binding="{Binding ExternalBridgeClientType}" Value="TCP"> + <Setter Property="Kind" Value="Lan"></Setter> + <Setter Property="Foreground" Value="{StaticResource FSE_LanBrush}"></Setter> + </DataTrigger> + <DataTrigger Binding="{Binding ExternalBridgeClientType}" Value="Wifi"> + <Setter Property="Kind" Value="Wifi"></Setter> + <Setter Property="Foreground" Value="{StaticResource FSE_WifiBrush}"></Setter> + </DataTrigger> + <DataTrigger Binding="{Binding ExternalBridgeClientType}" Value="SignalR"> + <Setter Property="Kind" Value="Cloud"></Setter> + <Setter Property="Foreground" Value="{StaticResource FSE_SignalRBrush}"></Setter> + </DataTrigger> + <DataTrigger Binding="{Binding ExternalBridgeClientType}" Value="Emulator"> + <Setter Property="Kind" Value="SdCard"></Setter> + <Setter Property="Foreground" Value="{StaticResource FSE_EmulatorBrush}"></Setter> + </DataTrigger> + </Style.Triggers> + </Style> + </material:PackIcon.Style> + </material:PackIcon> + </Grid> + </Border> + </ControlTemplate> + </Setter.Value> + </Setter> + </Style> + +</ResourceDictionary>
\ No newline at end of file diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/MachineIcon.cs b/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/MachineIcon.cs new file mode 100644 index 000000000..349328676 --- /dev/null +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/MachineIcon.cs @@ -0,0 +1,54 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows; +using System.Windows.Controls; +using System.Windows.Data; +using System.Windows.Documents; +using System.Windows.Input; +using System.Windows.Media; +using System.Windows.Media.Imaging; +using System.Windows.Navigation; +using System.Windows.Shapes; + +namespace Tango.FSE.Common.Controls +{ + /// <summary> + /// Follow steps 1a or 1b and then 2 to use this custom control in a XAML file. + /// + /// Step 1a) Using this custom control in a XAML file that exists in the current project. + /// Add this XmlNamespace attribute to the root element of the markup file where it is + /// to be used: + /// + /// xmlns:MyNamespace="clr-namespace:Tango.FSE.Common.Controls" + /// + /// + /// Step 1b) Using this custom control in a XAML file that exists in a different project. + /// Add this XmlNamespace attribute to the root element of the markup file where it is + /// to be used: + /// + /// xmlns:MyNamespace="clr-namespace:Tango.FSE.Common.Controls;assembly=Tango.FSE.Common.Controls" + /// + /// You will also need to add a project reference from the project where the XAML file lives + /// to this project and Rebuild to avoid compilation errors: + /// + /// Right click on the target project in the Solution Explorer and + /// "Add Reference"->"Projects"->[Browse to and select this project] + /// + /// + /// Step 2) + /// Go ahead and use your control in the XAML file. + /// + /// <MyNamespace:MachineIcon/> + /// + /// </summary> + public class MachineIcon : Control + { + static MachineIcon() + { + DefaultStyleKeyProperty.OverrideMetadata(typeof(MachineIcon), new FrameworkPropertyMetadata(typeof(MachineIcon))); + } + } +} diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/MachineIcon.xaml b/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/MachineIcon.xaml new file mode 100644 index 000000000..e4e9e1b48 --- /dev/null +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/MachineIcon.xaml @@ -0,0 +1,30 @@ +<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" + xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" + xmlns:local="clr-namespace:Tango.FSE.Common.Controls"> + + <Style TargetType="{x:Type local:MachineIcon}"> + <Setter Property="Template"> + <Setter.Value> + <ControlTemplate TargetType="{x:Type local:MachineIcon}"> + <Border Background="{TemplateBinding Background}" + BorderBrush="{TemplateBinding BorderBrush}" + BorderThickness="{TemplateBinding BorderThickness}"> + <Image RenderOptions.BitmapScalingMode="Fant"> + <Image.Style> + <Style TargetType="Image"> + <Setter Property="Source" Value="{StaticResource FSE_Machine_Small}"></Setter> + <Style.Triggers> + <DataTrigger Binding="{Binding MachineType}" Value="1"> + <Setter Property="Source" Value="{StaticResource FSE_Machine_Eureka_Small}"></Setter> + </DataTrigger> + </Style.Triggers> + </Style> + </Image.Style> + </Image> + </Border> + </ControlTemplate> + </Setter.Value> + </Setter> + </Style> + +</ResourceDictionary>
\ No newline at end of file diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/MachineIconFull.cs b/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/MachineIconFull.cs new file mode 100644 index 000000000..c6f1da030 --- /dev/null +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/MachineIconFull.cs @@ -0,0 +1,25 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows; +using System.Windows.Controls; +using System.Windows.Data; +using System.Windows.Documents; +using System.Windows.Input; +using System.Windows.Media; +using System.Windows.Media.Imaging; +using System.Windows.Navigation; +using System.Windows.Shapes; + +namespace Tango.FSE.Common.Controls +{ + public class MachineIconFull : Control + { + static MachineIconFull() + { + DefaultStyleKeyProperty.OverrideMetadata(typeof(MachineIconFull), new FrameworkPropertyMetadata(typeof(MachineIconFull))); + } + } +} diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/MachineIconFull.xaml b/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/MachineIconFull.xaml new file mode 100644 index 000000000..10a4d655d --- /dev/null +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/MachineIconFull.xaml @@ -0,0 +1,30 @@ +<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" + xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" + xmlns:local="clr-namespace:Tango.FSE.Common.Controls"> + + <Style TargetType="{x:Type local:MachineIconFull}"> + <Setter Property="Template"> + <Setter.Value> + <ControlTemplate TargetType="{x:Type local:MachineIconFull}"> + <Border Background="{TemplateBinding Background}" + BorderBrush="{TemplateBinding BorderBrush}" + BorderThickness="{TemplateBinding BorderThickness}"> + <Image RenderOptions.BitmapScalingMode="Fant"> + <Image.Style> + <Style TargetType="Image"> + <Setter Property="Source" Value="{StaticResource FSE_Machine_Full}"></Setter> + <Style.Triggers> + <DataTrigger Binding="{Binding MachineType}" Value="1"> + <Setter Property="Source" Value="{StaticResource FSE_Machine_Eureka_Full}"></Setter> + </DataTrigger> + </Style.Triggers> + </Style> + </Image.Style> + </Image> + </Border> + </ControlTemplate> + </Setter.Value> + </Setter> + </Style> + +</ResourceDictionary>
\ No newline at end of file diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/MachineView.xaml b/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/MachineView.xaml index c82b5b460..25fc3f88e 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/MachineView.xaml +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/MachineView.xaml @@ -24,247 +24,426 @@ </UserControl.Resources> <Grid> - <Viewbox MaxWidth="1200" Grid.Row="1" > - <Grid VerticalAlignment="Top"> - - <Image IsHitTestVisible="False" Source="{StaticResource FSE_Machine_Full}" MaxWidth="800" RenderOptions.BitmapScalingMode="Fant"> - <!--<Image.Effect> + <Grid> + <Grid.Style> + <Style TargetType="Grid"> + <Setter Property="Visibility" Value="Visible"></Setter> + <Style.Triggers> + <DataTrigger Binding="{Binding Type}" Value="Eureka"> + <Setter Property="Visibility" Value="Hidden"></Setter> + </DataTrigger> + </Style.Triggers> + </Style> + </Grid.Style> + <Viewbox MaxWidth="1200" Grid.Row="1" > + <Grid VerticalAlignment="Top"> + <Grid> + <Image IsHitTestVisible="False" Source="{StaticResource FSE_Machine_Full}" MaxWidth="800" RenderOptions.BitmapScalingMode="Fant"> + <!--<Image.Effect> <DropShadowEffect ShadowDepth="0" BlurRadius="20" Opacity="1" RenderingBias="Performance" Color="DimGray"></DropShadowEffect> </Image.Effect>--> - </Image> + </Image> - <Canvas ClipToBounds="False" x:Name="canvas"> + <Canvas ClipToBounds="False" x:Name="canvas"> - <Grid x:Name="hardwareGrid" Width="180" ToolTip="{Binding Configuration.HardwareVersion.Name}" Height="27" Canvas.Left="342" Canvas.Top="80" Background="#6B303030" IsHitTestVisible="True"> - <Border BorderBrush="#6C6C6C" BorderThickness="1" IsHitTestVisible="False"> - <StackPanel Orientation="Horizontal"> - <Image Source="../Images/hardware.png" Width="10" VerticalAlignment="Center" Margin="5" RenderOptions.BitmapScalingMode="Fant"></Image> - <TextBlock Padding="2 0 2 0" VerticalAlignment="Center" TextAlignment="Center" Foreground="{StaticResource FSE_GrayBrush}" IsHitTestVisible="False" FontSize="12" TextWrapping="Wrap"> + <Grid x:Name="hardwareGrid" Width="180" ToolTip="{Binding Configuration.HardwareVersion.Name}" Height="27" Canvas.Left="342" Canvas.Top="80" Background="#6B303030" IsHitTestVisible="True"> + <Border BorderBrush="#6C6C6C" BorderThickness="1" IsHitTestVisible="False"> + <StackPanel Orientation="Horizontal"> + <Image Source="../Images/hardware.png" Width="10" VerticalAlignment="Center" Margin="5" RenderOptions.BitmapScalingMode="Fant"></Image> + <TextBlock Padding="2 0 2 0" VerticalAlignment="Center" TextAlignment="Center" Foreground="{StaticResource FSE_GrayBrush}" IsHitTestVisible="False" FontSize="12" TextWrapping="Wrap"> <Run Text="{Binding Configuration.HardwareVersion.Name}"></Run> <Run Text="{Binding Configuration.HardwareVersion.Version}"></Run> - </TextBlock> - </StackPanel> - </Border> - </Grid> + </TextBlock> + </StackPanel> + </Border> + </Grid> - <!--<TextBlock Canvas.Left="532" FontStyle="Italic" Foreground="Gray" Canvas.Top="-22">Hardware</TextBlock> + <!--<TextBlock Canvas.Left="532" FontStyle="Italic" Foreground="Gray" Canvas.Top="-22">Hardware</TextBlock> <Grid Width="97" Height="90" Canvas.Left="431" Canvas.Top="-13"> <Rectangle Stroke="Gray" VerticalAlignment="Top" StrokeThickness="1" StrokeDashArray="5" RenderTransformOrigin="0.5,0.5"/> <Rectangle Stroke="Gray" HorizontalAlignment="Left" StrokeThickness="1" StrokeDashArray="5" RenderTransformOrigin="0.5,0.5"/> </Grid>--> - <UniformGrid Width="310" Canvas.Top="295" Canvas.Left="420" TextElement.Foreground="#252525" Rows="1" Columns="10" TextElement.FontSize="9"> - <TextBlock HorizontalAlignment="Center">1</TextBlock> - <TextBlock HorizontalAlignment="Center">2</TextBlock> - <TextBlock HorizontalAlignment="Center">3</TextBlock> - <TextBlock HorizontalAlignment="Center">4</TextBlock> - <TextBlock HorizontalAlignment="Center">5</TextBlock> - <TextBlock HorizontalAlignment="Center">6</TextBlock> - <TextBlock HorizontalAlignment="Center">7</TextBlock> - <TextBlock HorizontalAlignment="Center">8</TextBlock> - <TextBlock HorizontalAlignment="Center">9</TextBlock> - <TextBlock HorizontalAlignment="Center">10</TextBlock> - </UniformGrid> + <UniformGrid Width="310" Canvas.Top="295" Canvas.Left="420" TextElement.Foreground="#252525" Rows="1" Columns="10" TextElement.FontSize="9"> + <TextBlock HorizontalAlignment="Center">1</TextBlock> + <TextBlock HorizontalAlignment="Center">2</TextBlock> + <TextBlock HorizontalAlignment="Center">3</TextBlock> + <TextBlock HorizontalAlignment="Center">4</TextBlock> + <TextBlock HorizontalAlignment="Center">5</TextBlock> + <TextBlock HorizontalAlignment="Center">6</TextBlock> + <TextBlock HorizontalAlignment="Center">7</TextBlock> + <TextBlock HorizontalAlignment="Center">8</TextBlock> + <TextBlock HorizontalAlignment="Center">9</TextBlock> + <TextBlock HorizontalAlignment="Center">10</TextBlock> + </UniformGrid> - <Grid x:Name="gridIds" Width="310" Height="195" Canvas.Top="314" Canvas.Left="420"> - <ListBox ItemsSource="{Binding Configuration.IdsPacks}" ScrollViewer.VerticalScrollBarVisibility="Disabled" ScrollViewer.HorizontalScrollBarVisibility="Disabled"> - <ListBox.ItemContainerStyle> - <Style TargetType="ListBoxItem" BasedOn="{StaticResource {x:Type ListBoxItem}}"> - <Setter Property="Padding" Value="0"></Setter> - <Setter Property="VerticalContentAlignment" Value="Stretch"></Setter> - <Setter Property="HorizontalContentAlignment" Value="Stretch"></Setter> - </Style> - </ListBox.ItemContainerStyle> - <ItemsControl.ItemsPanel> - <ItemsPanelTemplate> - <UniformGrid Columns="10"></UniformGrid> - </ItemsPanelTemplate> - </ItemsControl.ItemsPanel> - <ItemsControl.ItemTemplate> - <DataTemplate> - <Grid> - <Grid.RowDefinitions> - <RowDefinition Height="1*"/> - <RowDefinition Height="30"/> - </Grid.RowDefinitions> - <UniformGrid Columns="1" Rows="2"> - <Grid Margin="2"> - <Image IsHitTestVisible="False" Source="../Images/dispenser.png" RenderOptions.BitmapScalingMode="Fant"> - <Image.Style> - <Style TargetType="Image"> - <Style.Triggers> - <DataTrigger Binding="{Binding Dispenser}" Value="{x:Null}"> - <Setter Property="Opacity" Value="0.2"></Setter> - </DataTrigger> - </Style.Triggers> - </Style> - </Image.Style> - </Image> - <Rectangle IsHitTestVisible="False" Margin="14 25 13 34"> - <Rectangle.Fill> - <LinearGradientBrush StartPoint="0,0" EndPoint="0,0.8" Opacity="0.8"> - <GradientStop Offset="0" Color="Transparent" /> - <GradientStop Offset="1" Color="{Binding LiquidType.Color,Converter={StaticResource ColorToIntegerConverter}}"/> - </LinearGradientBrush> - </Rectangle.Fill> - </Rectangle> - </Grid> + <Grid x:Name="gridIds" Width="310" Height="195" Canvas.Top="314" Canvas.Left="420"> + <ListBox ItemsSource="{Binding Configuration.IdsPacks}" ScrollViewer.VerticalScrollBarVisibility="Disabled" ScrollViewer.HorizontalScrollBarVisibility="Disabled"> + <ListBox.ItemContainerStyle> + <Style TargetType="ListBoxItem" BasedOn="{StaticResource {x:Type ListBoxItem}}"> + <Setter Property="Padding" Value="0"></Setter> + <Setter Property="VerticalContentAlignment" Value="Stretch"></Setter> + <Setter Property="HorizontalContentAlignment" Value="Stretch"></Setter> + </Style> + </ListBox.ItemContainerStyle> + <ItemsControl.ItemsPanel> + <ItemsPanelTemplate> + <UniformGrid Columns="10"></UniformGrid> + </ItemsPanelTemplate> + </ItemsControl.ItemsPanel> + <ItemsControl.ItemTemplate> + <DataTemplate> + <Grid> + <Grid.RowDefinitions> + <RowDefinition Height="1*"/> + <RowDefinition Height="30"/> + </Grid.RowDefinitions> + <UniformGrid Columns="1" Rows="2"> + <Grid Margin="2"> + <Image IsHitTestVisible="False" Source="../Images/dispenser.png" RenderOptions.BitmapScalingMode="Fant"> + <Image.Style> + <Style TargetType="Image"> + <Style.Triggers> + <DataTrigger Binding="{Binding Dispenser}" Value="{x:Null}"> + <Setter Property="Opacity" Value="0.2"></Setter> + </DataTrigger> + </Style.Triggers> + </Style> + </Image.Style> + </Image> + <Rectangle IsHitTestVisible="False" Margin="14 25 13 34"> + <Rectangle.Fill> + <LinearGradientBrush StartPoint="0,0" EndPoint="0,0.8" Opacity="0.8"> + <GradientStop Offset="0" Color="Transparent" /> + <GradientStop Offset="1" Color="{Binding LiquidType.Color,Converter={StaticResource ColorToIntegerConverter}}"/> + </LinearGradientBrush> + </Rectangle.Fill> + </Rectangle> + </Grid> + + <Grid Margin="2"> + <Image IsHitTestVisible="False" Stretch="Fill" Source="../Images/mid-tank.png" RenderOptions.BitmapScalingMode="Fant"> + <Image.Style> + <Style TargetType="Image"> + <Style.Triggers> + <DataTrigger Binding="{Binding MidTankType}" Value="{x:Null}"> + <Setter Property="Opacity" Value="0.2"></Setter> + </DataTrigger> + </Style.Triggers> + </Style> + </Image.Style> + </Image> + <Rectangle IsHitTestVisible="False" Margin="4 25 4 1"> + <Rectangle.Fill> + <LinearGradientBrush StartPoint="0,0" EndPoint="0,0.8" Opacity="0.8"> + <GradientStop Offset="0" Color="Transparent" /> + <GradientStop Offset="1" Color="{Binding LiquidType.Color,Converter={StaticResource ColorToIntegerConverter}}"/> + </LinearGradientBrush> + </Rectangle.Fill> + </Rectangle> + </Grid> + </UniformGrid> - <Grid Margin="2"> - <Image IsHitTestVisible="False" Stretch="Fill" Source="../Images/mid-tank.png" RenderOptions.BitmapScalingMode="Fant"> - <Image.Style> - <Style TargetType="Image"> + <Grid Grid.Row="1" Margin="3" IsHitTestVisible="False"> + <Grid.Style> + <Style TargetType="Grid"> <Style.Triggers> - <DataTrigger Binding="{Binding MidTankType}" Value="{x:Null}"> + <DataTrigger Binding="{Binding CartridgeType}" Value="{x:Null}"> <Setter Property="Opacity" Value="0.2"></Setter> </DataTrigger> </Style.Triggers> </Style> - </Image.Style> - </Image> - <Rectangle IsHitTestVisible="False" Margin="4 25 4 1"> - <Rectangle.Fill> - <LinearGradientBrush StartPoint="0,0" EndPoint="0,0.8" Opacity="0.8"> - <GradientStop Offset="0" Color="Transparent" /> - <GradientStop Offset="1" Color="{Binding LiquidType.Color,Converter={StaticResource ColorToIntegerConverter}}"/> - </LinearGradientBrush> - </Rectangle.Fill> - </Rectangle> + </Grid.Style> + <Border BorderBrush="#252525" BorderThickness="1" CornerRadius="3"> + <Border.Background> + <LinearGradientBrush> + <GradientStop Color="#FF252525"/> + <GradientStop Color="#FF838383" Offset="1"/> + </LinearGradientBrush> + </Border.Background> + </Border> + <Border BorderBrush="#252525" BorderThickness="1" CornerRadius="3"> + <Border.Background> + <LinearGradientBrush Opacity="0.7"> + <GradientStop Offset="0" Color="Transparent" /> + <GradientStop Offset="1" Color="{Binding LiquidType.Color,Converter={StaticResource ColorToIntegerConverter}}"/> + </LinearGradientBrush> + </Border.Background> + </Border> + </Grid> </Grid> - </UniformGrid> + </DataTemplate> + </ItemsControl.ItemTemplate> + </ListBox> - <Grid Grid.Row="1" Margin="3" IsHitTestVisible="False"> - <Grid.Style> - <Style TargetType="Grid"> - <Style.Triggers> - <DataTrigger Binding="{Binding CartridgeType}" Value="{x:Null}"> - <Setter Property="Opacity" Value="0.2"></Setter> - </DataTrigger> - </Style.Triggers> - </Style> - </Grid.Style> - <Border BorderBrush="#252525" BorderThickness="1" CornerRadius="3"> - <Border.Background> - <LinearGradientBrush> - <GradientStop Color="#FF252525"/> - <GradientStop Color="#FF838383" Offset="1"/> - </LinearGradientBrush> - </Border.Background> - </Border> - <Border BorderBrush="#252525" BorderThickness="1" CornerRadius="3"> - <Border.Background> - <LinearGradientBrush Opacity="0.7"> - <GradientStop Offset="0" Color="Transparent" /> - <GradientStop Offset="1" Color="{Binding LiquidType.Color,Converter={StaticResource ColorToIntegerConverter}}"/> - </LinearGradientBrush> - </Border.Background> - </Border> - </Grid> - </Grid> - </DataTemplate> - </ItemsControl.ItemTemplate> - </ListBox> - - <Grid Margin="0 50 0 0"> - <Grid.Style> - <Style TargetType="Grid"> - <Setter Property="Visibility" Value="Hidden"></Setter> - <Style.Triggers> - <DataTrigger Binding="{Binding Configuration.IdsPacks.Count}" Value="0"> - <Setter Property="Visibility" Value="Visible"></Setter> - </DataTrigger> - </Style.Triggers> - </Style> - </Grid.Style> - <TextBlock VerticalAlignment="Center" HorizontalAlignment="Center" FontSize="20" FontWeight="Bold" Foreground="{StaticResource FSE_GrayBrush}">NO IDS PACKS</TextBlock> - </Grid> + <Grid Margin="0 50 0 0"> + <Grid.Style> + <Style TargetType="Grid"> + <Setter Property="Visibility" Value="Hidden"></Setter> + <Style.Triggers> + <DataTrigger Binding="{Binding Configuration.IdsPacks.Count}" Value="0"> + <Setter Property="Visibility" Value="Visible"></Setter> + </DataTrigger> + </Style.Triggers> + </Style> + </Grid.Style> + <TextBlock VerticalAlignment="Center" HorizontalAlignment="Center" FontSize="20" FontWeight="Bold" Foreground="{StaticResource FSE_GrayBrush}">NO IDS PACKS</TextBlock> + </Grid> - <Rectangle VerticalAlignment="Bottom" Stroke="DimGray" StrokeThickness="2"> - <!--<Rectangle.Effect> + <Rectangle VerticalAlignment="Bottom" Stroke="DimGray" StrokeThickness="2"> + <!--<Rectangle.Effect> <DropShadowEffect ShadowDepth="1" Opacity="1" Color="Black" /> </Rectangle.Effect>--> - </Rectangle> - </Grid> + </Rectangle> + </Grid> - <Grid x:Name="gridEmbedded" Width="70" Height="100" Canvas.Left="80" Canvas.Top="331" IsHitTestVisible="True" SnapsToDevicePixels="True"> - <Image Source="../Images/ti-tm4c129x.png" RenderOptions.BitmapScalingMode="Fant"></Image> - </Grid> + <Grid x:Name="gridEmbedded" Width="70" Height="100" Canvas.Left="80" Canvas.Top="331" IsHitTestVisible="True" SnapsToDevicePixels="True"> + <Image Source="../Images/ti-tm4c129x.png" RenderOptions.BitmapScalingMode="Fant"></Image> + </Grid> - <Grid Width="61" IsHitTestVisible="True" SnapsToDevicePixels="True" ClipToBounds="True" Height="42" Canvas.Left="85" Canvas.Top="385"> - <Grid.RowDefinitions> - <RowDefinition Height="1*" /> - </Grid.RowDefinitions> + <Grid Width="61" IsHitTestVisible="True" SnapsToDevicePixels="True" ClipToBounds="True" Height="42" Canvas.Left="85" Canvas.Top="385"> + <Grid.RowDefinitions> + <RowDefinition Height="1*" /> + </Grid.RowDefinitions> - <StackPanel Orientation="Horizontal"> - <Image Source="../Images/embedded.png" Width="10" VerticalAlignment="Center" Margin="1" RenderOptions.BitmapScalingMode="Fant"></Image> - <TextBlock VerticalAlignment="Center" Padding="1" Foreground="{StaticResource FSE_GrayBrush}" IsHitTestVisible="False" FontSize="5" TextAlignment="Center" TextWrapping="Wrap" Height="15" Margin="0,6,0,0" Width="47"><Run Text="{Binding Configuration.EmbeddedFirmwareVersion.Name}"/><Run Text=" "/><Run Text="{Binding Configuration.EmbeddedFirmwareVersion.Version}"/></TextBlock> - </StackPanel> - </Grid> + <StackPanel Orientation="Horizontal"> + <Image Source="../Images/embedded.png" Width="10" VerticalAlignment="Center" Margin="1" RenderOptions.BitmapScalingMode="Fant"></Image> + <TextBlock VerticalAlignment="Center" Padding="1" Foreground="{StaticResource FSE_GrayBrush}" IsHitTestVisible="False" FontSize="5" TextAlignment="Center" TextWrapping="Wrap" Height="15" Margin="0,6,0,0" Width="47"><Run Text="{Binding Configuration.EmbeddedFirmwareVersion.Name}"/><Run Text=" "/><Run Text="{Binding Configuration.EmbeddedFirmwareVersion.Version}"/></TextBlock> + </StackPanel> + </Grid> - <TextBlock Canvas.Top="163" Canvas.Left="288" FontStyle="Italic" Foreground="Gray">Touch Panel</TextBlock> - <Grid Width="53" Height="55" Canvas.Top="184" Canvas.Left="279"> - <Rectangle Stroke="Gray" VerticalAlignment="Bottom" StrokeThickness="2" StrokeDashArray="5" RenderTransformOrigin="0.5,0.5"/> - <Rectangle Stroke="Gray" HorizontalAlignment="Right" StrokeThickness="1" StrokeDashArray="5" RenderTransformOrigin="0.5,0.5"/> - </Grid> + <TextBlock Canvas.Top="163" Canvas.Left="288" FontStyle="Italic" Foreground="Gray">Touch Panel</TextBlock> + <Grid Width="53" Height="55" Canvas.Top="184" Canvas.Left="279"> + <Rectangle Stroke="Gray" VerticalAlignment="Bottom" StrokeThickness="2" StrokeDashArray="5" RenderTransformOrigin="0.5,0.5"/> + <Rectangle Stroke="Gray" HorizontalAlignment="Right" StrokeThickness="1" StrokeDashArray="5" RenderTransformOrigin="0.5,0.5"/> + </Grid> - <TextBlock Canvas.Top="441" Canvas.Left="156" FontStyle="Italic" Foreground="Gray">Embedded Firmware</TextBlock> - <Grid Width="82" Height="26" Canvas.Top="410" Canvas.Left="158"> - <Rectangle Stroke="Gray" VerticalAlignment="Top" StrokeThickness="1" StrokeDashArray="5" RenderTransformOrigin="0.5,0.5"/> - <Rectangle Stroke="Gray" HorizontalAlignment="Right" StrokeThickness="1" StrokeDashArray="6" RenderTransformOrigin="0.5,0.5"/> - </Grid> + <TextBlock Canvas.Top="441" Canvas.Left="156" FontStyle="Italic" Foreground="Gray">Embedded Firmware</TextBlock> + <Grid Width="82" Height="26" Canvas.Top="410" Canvas.Left="158"> + <Rectangle Stroke="Gray" VerticalAlignment="Top" StrokeThickness="1" StrokeDashArray="5" RenderTransformOrigin="0.5,0.5"/> + <Rectangle Stroke="Gray" HorizontalAlignment="Right" StrokeThickness="1" StrokeDashArray="6" RenderTransformOrigin="0.5,0.5"/> + </Grid> - <TextBlock Canvas.Top="310" Canvas.Left="340" FontStyle="Italic" Foreground="Gray">Dispensers</TextBlock> - <Grid Width="53" Height="20" Canvas.Top="331" Canvas.Left="377"> - <Rectangle Stroke="Gray" VerticalAlignment="Bottom" StrokeThickness="2" StrokeDashArray="3" RenderTransformOrigin="0.5,0.5"/> - <Rectangle Stroke="Gray" HorizontalAlignment="Left" StrokeThickness="2" StrokeDashArray="3" RenderTransformOrigin="0.5,0.5"/> - </Grid> + <TextBlock Canvas.Top="310" Canvas.Left="340" FontStyle="Italic" Foreground="Gray">Dispensers</TextBlock> + <Grid Width="53" Height="20" Canvas.Top="331" Canvas.Left="377"> + <Rectangle Stroke="Gray" VerticalAlignment="Bottom" StrokeThickness="2" StrokeDashArray="3" RenderTransformOrigin="0.5,0.5"/> + <Rectangle Stroke="Gray" HorizontalAlignment="Left" StrokeThickness="2" StrokeDashArray="3" RenderTransformOrigin="0.5,0.5"/> + </Grid> - <!--<TextBlock Canvas.Top="395" Canvas.Left="331" FontStyle="Italic" Foreground="Gray">Mid Tanks</TextBlock> + <!--<TextBlock Canvas.Top="395" Canvas.Left="331" FontStyle="Italic" Foreground="Gray">Mid Tanks</TextBlock> <Grid Width="62" Height="29" Canvas.Top="418" Canvas.Left="357"> <Rectangle Stroke="Gray" VerticalAlignment="Bottom" StrokeThickness="2" StrokeDashArray="4" RenderTransformOrigin="0.5,0.5"/> <Rectangle Stroke="Gray" HorizontalAlignment="Left" StrokeThickness="1" StrokeDashArray="5" RenderTransformOrigin="0.5,0.5"/> </Grid>--> - <!--<TextBlock Canvas.Top="469" Canvas.Left="304" FontStyle="Italic" Foreground="Gray">Cartridges</TextBlock> + <!--<TextBlock Canvas.Top="469" Canvas.Left="304" FontStyle="Italic" Foreground="Gray">Cartridges</TextBlock> <Grid Width="87" Height="10" Canvas.Top="487" Canvas.Left="332"> <Rectangle Stroke="Gray" VerticalAlignment="Bottom" StrokeThickness="2" StrokeDashArray="5" RenderTransformOrigin="0.5,0.5"/> <Rectangle Stroke="Gray" HorizontalAlignment="Left" StrokeThickness="2" StrokeDashArray="5" RenderTransformOrigin="0.5,0.5"/> </Grid>--> - <Grid x:Name="gridTablet" Width="67" IsHitTestVisible="True" SnapsToDevicePixels="True" ClipToBounds="True" Height="90" Canvas.Left="188" Canvas.Top="198"> - <Grid.RowDefinitions> - <RowDefinition Height="1*" /> - <RowDefinition Height="1*" /> - <RowDefinition Height="1*" /> - </Grid.RowDefinitions> + <Grid x:Name="gridTablet" Width="67" IsHitTestVisible="True" SnapsToDevicePixels="True" ClipToBounds="True" Height="90" Canvas.Left="188" Canvas.Top="198"> + <Grid.RowDefinitions> + <RowDefinition Height="1*" /> + <RowDefinition Height="1*" /> + <RowDefinition Height="1*" /> + </Grid.RowDefinitions> - <StackPanel> - <Image Source="../Images/tablet.png" Width="10" Margin="2" RenderOptions.BitmapScalingMode="Fant"></Image> - <TextBlock Padding="2 0 2 0" Foreground="{StaticResource FSE_GrayBrush}" IsHitTestVisible="False" FontSize="6" TextAlignment="Center" TextWrapping="Wrap"> + <StackPanel> + <Image Source="../Images/tablet.png" Width="10" Margin="2" RenderOptions.BitmapScalingMode="Fant"></Image> + <TextBlock Padding="2 0 2 0" Foreground="{StaticResource FSE_GrayBrush}" IsHitTestVisible="False" FontSize="6" TextAlignment="Center" TextWrapping="Wrap"> <Run Text="{Binding Configuration.ApplicationDisplayPanelVersion.Name}"></Run> <Run Text="{Binding Configuration.ApplicationDisplayPanelVersion.Version}"></Run> - </TextBlock> - </StackPanel> + </TextBlock> + </StackPanel> - <StackPanel Grid.Row="3" > - <Image Source="../Images/application-firmware.png" Width="10" Margin="2" RenderOptions.BitmapScalingMode="Fant"></Image> - <TextBlock Padding="2 0 2 0" IsHitTestVisible="False" Foreground="{StaticResource FSE_GrayBrush}" FontSize="6" TextAlignment="Center" TextWrapping="Wrap"> + <StackPanel Grid.Row="3" > + <Image Source="../Images/application-firmware.png" Width="10" Margin="2" RenderOptions.BitmapScalingMode="Fant"></Image> + <TextBlock Padding="2 0 2 0" IsHitTestVisible="False" Foreground="{StaticResource FSE_GrayBrush}" FontSize="6" TextAlignment="Center" TextWrapping="Wrap"> <Run Text="{Binding Configuration.ApplicationFirmwareVersion.Name}"></Run> <Run Text="{Binding Configuration.ApplicationFirmwareVersion.Version}"></Run> - </TextBlock> - </StackPanel> + </TextBlock> + </StackPanel> - <StackPanel Grid.Row="1" > - <Image Source="../Images/android.png" Width="10" Margin="2" RenderOptions.BitmapScalingMode="Fant"></Image> - <TextBlock Padding="2 0 2 0" IsHitTestVisible="False" Foreground="{StaticResource FSE_GrayBrush}" FontSize="6" TextAlignment="Center" TextWrapping="Wrap"> + <StackPanel Grid.Row="1" > + <Image Source="../Images/android.png" Width="10" Margin="2" RenderOptions.BitmapScalingMode="Fant"></Image> + <TextBlock Padding="2 0 2 0" IsHitTestVisible="False" Foreground="{StaticResource FSE_GrayBrush}" FontSize="6" TextAlignment="Center" TextWrapping="Wrap"> <Run Text="{Binding Configuration.ApplicationOsVersion.Name}"></Run> <Run Text="{Binding Configuration.ApplicationOsVersion.Version}"></Run> + </TextBlock> + </StackPanel> + </Grid> + </Canvas> + + </Grid> + + </Grid> + </Viewbox> + </Grid> + + <Grid> + <Grid.Style> + <Style TargetType="Grid"> + <Setter Property="Visibility" Value="Hidden"></Setter> + <Style.Triggers> + <DataTrigger Binding="{Binding Type}" Value="Eureka"> + <Setter Property="Visibility" Value="Visible"></Setter> + </DataTrigger> + </Style.Triggers> + </Style> + </Grid.Style> + <Viewbox MaxWidth="1200" Grid.Row="1" Margin="25 0 0 0"> + <Grid IsHitTestVisible="False" VerticalAlignment="Top"> + + <Image IsHitTestVisible="False" Source="{StaticResource FSE_Machine_Eureka_Full}" MaxWidth="1000" Margin="-150 -50 0 0" RenderOptions.BitmapScalingMode="Fant"/> + + <StackPanel Margin="160 150 0 0" Width="410" HorizontalAlignment="Left"> + <UniformGrid TextElement.Foreground="#252525" Rows="1" Columns="10" TextElement.FontSize="20"> + <TextBlock HorizontalAlignment="Center">1</TextBlock> + <TextBlock HorizontalAlignment="Center">2</TextBlock> + <TextBlock HorizontalAlignment="Center">3</TextBlock> + <TextBlock HorizontalAlignment="Center">4</TextBlock> + <TextBlock HorizontalAlignment="Center">5</TextBlock> + <TextBlock HorizontalAlignment="Center">6</TextBlock> + <TextBlock HorizontalAlignment="Center">7</TextBlock> + <TextBlock HorizontalAlignment="Center">8</TextBlock> + <TextBlock HorizontalAlignment="Center">9</TextBlock> + <TextBlock HorizontalAlignment="Center">10</TextBlock> + </UniformGrid> + + <Grid Height="218"> + <ListBox ItemsSource="{Binding Configuration.IdsPacks}" ScrollViewer.VerticalScrollBarVisibility="Disabled" ScrollViewer.HorizontalScrollBarVisibility="Disabled" Background="Transparent"> + <ListBox.ItemContainerStyle> + <Style TargetType="ListBoxItem" BasedOn="{StaticResource {x:Type ListBoxItem}}"> + <Setter Property="Padding" Value="0"></Setter> + <Setter Property="VerticalContentAlignment" Value="Stretch"></Setter> + <Setter Property="HorizontalContentAlignment" Value="Stretch"></Setter> + </Style> + </ListBox.ItemContainerStyle> + <ItemsControl.ItemsPanel> + <ItemsPanelTemplate> + <UniformGrid Columns="10"></UniformGrid> + </ItemsPanelTemplate> + </ItemsControl.ItemsPanel> + <ItemsControl.ItemTemplate> + <DataTemplate> + <Grid> + <Grid.RowDefinitions> + <RowDefinition Height="1*"/> + <RowDefinition Height="30"/> + </Grid.RowDefinitions> + <UniformGrid Columns="1" Rows="2"> + <Grid Margin="2"> + <Image IsHitTestVisible="False" Source="../Images/dispenser.png" RenderOptions.BitmapScalingMode="Fant"> + <Image.Style> + <Style TargetType="Image"> + <Style.Triggers> + <DataTrigger Binding="{Binding Dispenser}" Value="{x:Null}"> + <Setter Property="Opacity" Value="0.2"></Setter> + </DataTrigger> + </Style.Triggers> + </Style> + </Image.Style> + </Image> + <Rectangle IsHitTestVisible="False" Margin="14 25 13 34"> + <Rectangle.Fill> + <LinearGradientBrush StartPoint="0,0" EndPoint="0,0.8" Opacity="0.8"> + <GradientStop Offset="0" Color="Transparent" /> + <GradientStop Offset="1" Color="{Binding LiquidType.Color,Converter={StaticResource ColorToIntegerConverter}}"/> + </LinearGradientBrush> + </Rectangle.Fill> + </Rectangle> + </Grid> + + <Grid Margin="2"> + <Image IsHitTestVisible="False" Stretch="Fill" Source="../Images/mid-tank.png" RenderOptions.BitmapScalingMode="Fant"> + <Image.Style> + <Style TargetType="Image"> + <Style.Triggers> + <DataTrigger Binding="{Binding MidTankType}" Value="{x:Null}"> + <Setter Property="Opacity" Value="0.2"></Setter> + </DataTrigger> + </Style.Triggers> + </Style> + </Image.Style> + </Image> + <Rectangle IsHitTestVisible="False" Margin="4 25 4 1"> + <Rectangle.Fill> + <LinearGradientBrush StartPoint="0,0" EndPoint="0,0.8" Opacity="0.8"> + <GradientStop Offset="0" Color="Transparent" /> + <GradientStop Offset="1" Color="{Binding LiquidType.Color,Converter={StaticResource ColorToIntegerConverter}}"/> + </LinearGradientBrush> + </Rectangle.Fill> + </Rectangle> + </Grid> + </UniformGrid> + + <Grid Grid.Row="1" Margin="3" IsHitTestVisible="False"> + <Grid.Style> + <Style TargetType="Grid"> + <Style.Triggers> + <DataTrigger Binding="{Binding CartridgeType}" Value="{x:Null}"> + <Setter Property="Opacity" Value="0.2"></Setter> + </DataTrigger> + </Style.Triggers> + </Style> + </Grid.Style> + <Border BorderBrush="#252525" BorderThickness="1" CornerRadius="3"> + <Border.Background> + <LinearGradientBrush> + <GradientStop Color="#FF252525"/> + <GradientStop Color="#FF838383" Offset="1"/> + </LinearGradientBrush> + </Border.Background> + </Border> + <Border BorderBrush="#252525" BorderThickness="1" CornerRadius="3"> + <Border.Background> + <LinearGradientBrush Opacity="0.7"> + <GradientStop Offset="0" Color="Transparent" /> + <GradientStop Offset="1" Color="{Binding LiquidType.Color,Converter={StaticResource ColorToIntegerConverter}}"/> + </LinearGradientBrush> + </Border.Background> + </Border> + </Grid> + </Grid> + </DataTemplate> + </ItemsControl.ItemTemplate> + </ListBox> + + <Grid Margin="0 50 0 0"> + <Grid.Style> + <Style TargetType="Grid"> + <Setter Property="Visibility" Value="Hidden"></Setter> + <Style.Triggers> + <DataTrigger Binding="{Binding Configuration.IdsPacks.Count}" Value="0"> + <Setter Property="Visibility" Value="Visible"></Setter> + </DataTrigger> + </Style.Triggers> + </Style> + </Grid.Style> + <TextBlock VerticalAlignment="Center" HorizontalAlignment="Center" FontSize="20" FontWeight="Bold" Foreground="{StaticResource FSE_GrayBrush}">NO IDS PACKS</TextBlock> + </Grid> + + <Rectangle VerticalAlignment="Bottom" Stroke="DimGray" StrokeThickness="2"> + <!--<Rectangle.Effect> + <DropShadowEffect ShadowDepth="1" Opacity="1" Color="Black" /> + </Rectangle.Effect>--> + </Rectangle> + </Grid> + </StackPanel> + + <Border Margin="150 30 0 0" BorderThickness="1" IsHitTestVisible="False" HorizontalAlignment="Left" VerticalAlignment="Top"> + <StackPanel Orientation="Horizontal"> + <Image Source="../Images/hardware.png" Width="30" VerticalAlignment="Center" Margin="5" RenderOptions.BitmapScalingMode="Fant"></Image> + <TextBlock Padding="2 0 2 0" VerticalAlignment="Center" TextAlignment="Center" Foreground="{StaticResource FSE_GrayBrush}" IsHitTestVisible="False" FontSize="20" TextWrapping="Wrap"> + <Run Text="{Binding Configuration.HardwareVersion.Name}"></Run> + <Run Text="{Binding Configuration.HardwareVersion.Version}"></Run> </TextBlock> </StackPanel> - </Grid> - </Canvas> - </Grid> - </Viewbox> + </Border> + </Grid> + </Viewbox> + </Grid> </Grid> </UserControl> diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/RunningJobRingProgress.xaml b/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/RunningJobRingProgress.xaml index d0121afa5..b683ae0d2 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/RunningJobRingProgress.xaml +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/RunningJobRingProgress.xaml @@ -5,9 +5,14 @@ xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:behaviors="clr-namespace:Tango.FSE.Common.Behaviors" xmlns:local="clr-namespace:Tango.FSE.Common.Controls" + xmlns:localConverters="clr-namespace:Tango.FSE.Common.Converters" xmlns:material="http://materialdesigninxaml.net/winfx/xaml/themes" mc:Ignorable="d" d:DesignHeight="450" d:DesignWidth="450" x:Name="control"> + <UserControl.Resources> + <localConverters:ProgressLengthSpoolConverter x:Key="ProgressLengthSpoolConverter"/> + </UserControl.Resources> + <Grid Opacity="0.7"> <Viewbox> <Grid> @@ -50,10 +55,31 @@ <TextBlock Margin="5 0 0 0" VerticalAlignment="Center">Completed</TextBlock> </StackPanel> - <TextBlock FontWeight="Light" FontSize="25" Margin="0 10 0 0" HorizontalAlignment="Center"> + <TextBlock FontWeight="Light" FontSize="25" Margin="0 10 0 0" HorizontalAlignment="Center" Visibility="Collapsed"> <Run Text="{Binding ElementName=control,Path=RunningJobStatus.ProgressMinusSettingUp,StringFormat=0,FallbackValue=0}"></Run><Run Text="/" /><Run Text="{Binding RunningJobStatus.TotalProgressMinusSettingUp,StringFormat=0,FallbackValue=0}"/> <Run FontSize="16">m</Run> </TextBlock> + <StackPanel Orientation="Horizontal" Margin="0 10 0 0" HorizontalAlignment="Center" Visibility="Visible"> + <TextBlock FontWeight="Light" FontSize="25" VerticalAlignment="Center" > + <TextBlock.Text> + <MultiBinding Converter="{StaticResource ProgressLengthSpoolConverter}" StringFormat="0.#" TargetNullValue='-' FallbackValue='0' Mode="OneWay"> + <Binding Path="RunningJobStatus.TotalProgressMinusSettingUp" /> + <Binding Path="IsEureka"/> + <Binding Path="RunningJobStatus.ProgressMinusSettingUp" /> + </MultiBinding> + </TextBlock.Text> + </TextBlock> + <TextBlock FontWeight="Light" FontSize="25" VerticalAlignment="Center" Text="/"></TextBlock> + <TextBlock FontWeight="Light" FontSize="25" VerticalAlignment="Center" > + <TextBlock.Text> + <MultiBinding Converter="{StaticResource ProgressLengthSpoolConverter}" StringFormat="0" TargetNullValue='-' FallbackValue='0' Mode="OneWay"> + <Binding Path="RunningJobStatus.TotalProgressMinusSettingUp"/> + <Binding Path="IsEureka"/> + </MultiBinding> + </TextBlock.Text> + </TextBlock> + <TextBlock FontWeight="Light" FontSize="25" VerticalAlignment="Center" Text=" m"></TextBlock> + </StackPanel> </StackPanel> <StackPanel Height="90" Visibility="{Binding ElementName=control,Path=RunningJobStatus.IsSettingUp,Converter={StaticResource BooleanToVisibilityConverter}}"> diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/RunningJobRingProgress.xaml.cs b/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/RunningJobRingProgress.xaml.cs index 5e0f28419..d8374573c 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/RunningJobRingProgress.xaml.cs +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/RunningJobRingProgress.xaml.cs @@ -40,8 +40,15 @@ namespace Tango.FSE.Common.Controls public static readonly DependencyProperty IsRunningProperty = DependencyProperty.Register("IsRunning", typeof(bool), typeof(RunningJobRingProgress), new PropertyMetadata(false)); + public bool IsEureka + { + get { return (bool)GetValue(IsEurekaProperty); } + set { SetValue(IsEurekaProperty, value); } + } + public static readonly DependencyProperty IsEurekaProperty = + DependencyProperty.Register("IsEureka", typeof(bool), typeof(RunningJobRingProgress), new PropertyMetadata(false)); - + public RunningJobRingProgress() { InitializeComponent(); diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/RunningJobViewer.xaml b/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/RunningJobViewer.xaml index 2cd4fa7ad..faf5e072f 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/RunningJobViewer.xaml +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/RunningJobViewer.xaml @@ -6,9 +6,14 @@ xmlns:enumerations="clr-namespace:Tango.BL.Enumerations;assembly=Tango.BL" xmlns:material="http://materialdesigninxaml.net/winfx/xaml/themes" xmlns:local="clr-namespace:Tango.FSE.Common.Controls" + xmlns:localConverters="clr-namespace:Tango.FSE.Common.Converters" mc:Ignorable="d" d:DesignHeight="120" d:DesignWidth="800"> + <UserControl.Resources> + <localConverters:ProgressLengthSpoolConverter x:Key="ProgressLengthSpoolConverter"/> + </UserControl.Resources> + <DockPanel> <Canvas Height="50" Margin="0" DockPanel.Dock="Top"> <StackPanel> @@ -132,7 +137,15 @@ </Style.Triggers> </Style> </TextBlock.Style> - <Run Text="{Binding LengthWithFactor,Mode=OneWay,StringFormat=N0}"></Run><Run Text="m"></Run> + <Run > + <Run.Text> + <MultiBinding Converter="{StaticResource ProgressLengthSpoolConverter}" StringFormat="N0" TargetNullValue=' ' FallbackValue='0' Mode="OneWay"> + <Binding Path="LengthWithFactor"/> + <Binding RelativeSource="{RelativeSource AncestorType=UserControl}" Path="IsEureka"/> + </MultiBinding> + </Run.Text> + </Run> + <Run Text="m"></Run> </TextBlock> </Grid> </DataTemplate> diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/RunningJobViewer.xaml.cs b/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/RunningJobViewer.xaml.cs index 4a970ffda..459728264 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/RunningJobViewer.xaml.cs +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Controls/RunningJobViewer.xaml.cs @@ -55,6 +55,14 @@ namespace Tango.FSE.Common.Controls public static readonly DependencyProperty JobProperty = DependencyProperty.Register("Job", typeof(Job), typeof(RunningJobViewer), new PropertyMetadata(null)); + public bool IsEureka + { + get { return (bool)GetValue(IsEurekaProperty); } + set { SetValue(IsEurekaProperty, value); } + } + public static readonly DependencyProperty IsEurekaProperty = + DependencyProperty.Register("IsEureka", typeof(bool), typeof(RunningJobViewer), new PropertyMetadata(false)); + /// <summary> /// Gets or sets the running job status. /// </summary> diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Converters/ProgressLengthSpoolConverter.cs b/Software/Visual_Studio/FSE/Tango.FSE.Common/Converters/ProgressLengthSpoolConverter.cs new file mode 100644 index 000000000..10c20c171 --- /dev/null +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Converters/ProgressLengthSpoolConverter.cs @@ -0,0 +1,61 @@ +using System; +using System.Collections.Generic; +using System.Globalization; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows; +using System.Windows.Data; +using Tango.BL.Entities; + +namespace Tango.FSE.Common.Converters +{ + public class ProgressLengthSpoolConverter : IMultiValueConverter + { + public object Convert(object[] values, Type targetType, object parameter, CultureInfo culture) + { + try + { + if (values.Count() == 2) + { + double length = System.Convert.ToDouble(values[0]); + bool isEureka = System.Convert.ToBoolean(values[1]); + int jobSpools = 1; + if (isEureka) + jobSpools = 4; + var totalBy4Spools = (double)length * jobSpools;// spools 4; + return totalBy4Spools; + + } + if (values.Count() == 3) + { + double length = System.Convert.ToDouble(values[0]); + var segment = values[1] as Segment; + bool isEureka = System.Convert.ToBoolean(values[1]); + int jobSpools = 1; + if (isEureka) + jobSpools = 4; + double currentProgresslength = System.Convert.ToDouble(values[2]); + + var totalBySpools = (double)length * jobSpools; + var currentProgressBySpools = (double)currentProgresslength * jobSpools; + + int coeff = (int)currentProgressBySpools / (int)totalBySpools; + var progressCurrent = (coeff == 0 || coeff == 1) ? currentProgressBySpools : currentProgressBySpools % (coeff * totalBySpools);//show for progress + + return progressCurrent; + } + return "-"; + } + catch + { + return "-"; + } + } + + public object[] ConvertBack(object value, Type[] targetTypes, object parameter, CultureInfo culture) + { + throw new NotImplementedException(); + } + } +} diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/FSESettings.cs b/Software/Visual_Studio/FSE/Tango.FSE.Common/FSESettings.cs index d6b8bd492..f518ef2d2 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.Common/FSESettings.cs +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/FSESettings.cs @@ -190,6 +190,11 @@ namespace Tango.FSE.Common public StatisticsStreamingConfiguration StatisticsStreamingConfig { get; set; } /// <summary> + /// Gets or sets the last type of the connected machine. + /// </summary> + public int LastConnectedMachineType { get; set; } + + /// <summary> /// Initializes a new instance of the <see cref="FSESettings"/> class. /// </summary> public FSESettings() diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/Connections/emulator.png b/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/Connections/emulator.png Binary files differnew file mode 100644 index 000000000..cd3478ab2 --- /dev/null +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/Connections/emulator.png diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/Connections/eureka.png b/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/Connections/eureka.png Binary files differnew file mode 100644 index 000000000..212d391d4 --- /dev/null +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/Connections/eureka.png diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/Connections/signalr.png b/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/Connections/signalr.png Binary files differnew file mode 100644 index 000000000..20d329640 --- /dev/null +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/Connections/signalr.png diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/Connections/tcp.png b/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/Connections/tcp.png Binary files differnew file mode 100644 index 000000000..a19a64fec --- /dev/null +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/Connections/tcp.png diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/Connections/ts1800.png b/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/Connections/ts1800.png Binary files differnew file mode 100644 index 000000000..116e1e9c7 --- /dev/null +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/Connections/ts1800.png diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/Connections/usb.png b/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/Connections/usb.png Binary files differnew file mode 100644 index 000000000..d0b917b44 --- /dev/null +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/Connections/usb.png diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/Connections/wifi.png b/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/Connections/wifi.png Binary files differnew file mode 100644 index 000000000..8c4bfebc4 --- /dev/null +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/Connections/wifi.png diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/eureka_full.png b/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/eureka_full.png Binary files differnew file mode 100644 index 000000000..484bb2ac1 --- /dev/null +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/eureka_full.png diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/eureka_small.png b/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/eureka_small.png Binary files differnew file mode 100644 index 000000000..c9da4ae29 --- /dev/null +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/eureka_small.png diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/machines.png b/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/machines.png Binary files differnew file mode 100644 index 000000000..788d1e67b --- /dev/null +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Images/machines.png diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Resources/Colors.xaml b/Software/Visual_Studio/FSE/Tango.FSE.Common/Resources/Colors.xaml index 792826d31..e10b0678d 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.Common/Resources/Colors.xaml +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Resources/Colors.xaml @@ -22,6 +22,7 @@ <Color x:Key="FSE_MessageBoxTitleHeaderBackgroundColor">#404040</Color> <Color x:Key="FSE_UsbColor">#FF6F6F</Color> + <Color x:Key="FSE_LanColor">#EA6FFF</Color> <Color x:Key="FSE_WifiColor">#58C13B</Color> <Color x:Key="FSE_SignalRColor">#6DDAFF</Color> <Color x:Key="FSE_EmulatorColor">#F3FF6D</Color> @@ -66,6 +67,7 @@ <SolidColorBrush x:Key="FSE_MessageBoxTitleHeaderBackgroundBrush" Color="{StaticResource FSE_MessageBoxTitleHeaderBackgroundColor}"></SolidColorBrush> <SolidColorBrush x:Key="FSE_UsbBrush" Color="{StaticResource FSE_UsbColor}"></SolidColorBrush> + <SolidColorBrush x:Key="FSE_LanBrush" Color="{StaticResource FSE_LanColor}"></SolidColorBrush> <SolidColorBrush x:Key="FSE_WifiBrush" Color="{StaticResource FSE_WifiColor}"></SolidColorBrush> <SolidColorBrush x:Key="FSE_SignalRBrush" Color="{StaticResource FSE_SignalRColor}"></SolidColorBrush> <SolidColorBrush x:Key="FSE_EmulatorBrush" Color="{StaticResource FSE_EmulatorColor}"></SolidColorBrush> diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Resources/Controls.xaml b/Software/Visual_Studio/FSE/Tango.FSE.Common/Resources/Controls.xaml index e2b01843e..0204be2ea 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.Common/Resources/Controls.xaml +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Resources/Controls.xaml @@ -15,6 +15,9 @@ <ResourceDictionary Source="pack://application:,,,/Tango.FSE.Common;component/Controls/FSEGroupBox.xaml" /> <ResourceDictionary Source="pack://application:,,,/Tango.FSE.Common;component/Controls/FSERoundedCornersComboBox.xaml" /> <ResourceDictionary Source="pack://application:,,,/Tango.FSE.Common;component/Controls/SelectionComboBox.xaml" /> + <ResourceDictionary Source="pack://application:,,,/Tango.FSE.Common;component/Controls/MachineConnectionIcon.xaml" /> + <ResourceDictionary Source="pack://application:,,,/Tango.FSE.Common;component/Controls/MachineIcon.xaml" /> + <ResourceDictionary Source="pack://application:,,,/Tango.FSE.Common;component/Controls/MachineIconFull.xaml" /> </ResourceDictionary.MergedDictionaries> </ResourceDictionary>
\ No newline at end of file diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Resources/Images.xaml b/Software/Visual_Studio/FSE/Tango.FSE.Common/Resources/Images.xaml index 91bf1816f..e69b69e44 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.Common/Resources/Images.xaml +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Resources/Images.xaml @@ -4,7 +4,10 @@ <BitmapImage x:Key="FSE_Machine_Big" UriSource="../Images/machine_big.png" /> <BitmapImage x:Key="FSE_Machine_Small" UriSource="../Images/machine_small.png" /> + <BitmapImage x:Key="FSE_Machine_Eureka_Small" UriSource="../Images/eureka_small.png" /> <BitmapImage x:Key="FSE_Machine_Full" UriSource="../Images/machine_full.png" /> + <BitmapImage x:Key="FSE_Machine_Eureka_Full" UriSource="../Images/eureka_full.png" /> + <BitmapImage x:Key="FSE_Machines_Full" UriSource="../Images/machines.png" /> <BitmapImage x:Key="FSE_Twine_Logo" UriSource="../Images/twine_logo.png" /> <BitmapImage x:Key="FSE_Twine_Logo_Colored" UriSource="../Images/twine_logo_colored.png" /> <BitmapImage x:Key="FSE_PPC" UriSource="../Images/tablet.png" /> diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Resources/Styles.xaml b/Software/Visual_Studio/FSE/Tango.FSE.Common/Resources/Styles.xaml index 4b5d8f8d2..c7e36cafa 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.Common/Resources/Styles.xaml +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Resources/Styles.xaml @@ -4,6 +4,7 @@ xmlns:actions="clr-namespace:Tango.FSE.Common.EventTriggerActions" xmlns:material="http://materialdesigninxaml.net/winfx/xaml/themes" xmlns:controls="clr-namespace:Tango.SharedUI.Controls;assembly=Tango.SharedUI" + xmlns:commonControls="clr-namespace:Tango.FSE.Common.Controls" xmlns:wpf="http://materialdesigninxaml.net/winfx/xaml/themes" xmlns:mahapps="http://metro.mahapps.com/winfx/xaml/controls" xmlns:i="http://schemas.microsoft.com/expression/2010/interactivity" @@ -625,7 +626,7 @@ <Setter.Value> <DataTemplate> <DockPanel VerticalAlignment="Center"> - <Image RenderOptions.BitmapScalingMode="Fant" Source="{StaticResource FSE_Machine_Small}" Width="24" /> + <commonControls:MachineIcon Height="24" /> <StackPanel VerticalAlignment="Center" Margin="10 0 0 0" Orientation="Horizontal"> <TextBlock Text="{Binding SerialNumber}" FontSize="{StaticResource FSE_SmallFontSize}"></TextBlock> <TextBlock Margin="10 0 0 0" FontSize="{StaticResource FSE_SmallFontSize}" Foreground="{StaticResource FSE_GrayBrush}" Text="{Binding Name}"></TextBlock> @@ -638,7 +639,7 @@ <Setter.Value> <DataTemplate> <DockPanel VerticalAlignment="Center"> - <Image RenderOptions.BitmapScalingMode="Fant" Source="{StaticResource FSE_Machine_Small}" Width="32" /> + <commonControls:MachineIcon Height="32" /> <StackPanel Margin="5 0 0 0"> <TextBlock Text="{Binding SerialNumber}"></TextBlock> <TextBlock Margin="0 5 0 0" FontSize="{StaticResource FSE_SmallerFontSize}" Foreground="{StaticResource FSE_GrayBrush}" Text="{Binding Name}"></TextBlock> diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Tango.FSE.Common.csproj b/Software/Visual_Studio/FSE/Tango.FSE.Common/Tango.FSE.Common.csproj index 95ee0b2f5..8ef3551d5 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.Common/Tango.FSE.Common.csproj +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Tango.FSE.Common.csproj @@ -190,6 +190,9 @@ <Compile Include="Controls\FSEPanel.cs" /> <Compile Include="Controls\FSETabControl.cs" /> <Compile Include="Controls\IconButton.cs" /> + <Compile Include="Controls\MachineConnectionIcon.cs" /> + <Compile Include="Controls\MachineIcon.cs" /> + <Compile Include="Controls\MachineIconFull.cs" /> <Compile Include="Controls\MachineView.xaml.cs"> <DependentUpon>MachineView.xaml</DependentUpon> </Compile> @@ -217,6 +220,7 @@ <Compile Include="Converters\LiquidTypeToShortNameConverter.cs" /> <Compile Include="Converters\NanolitersToLitersConverter.cs" /> <Compile Include="Converters\ObjectToJsonConverter.cs" /> + <Compile Include="Converters\ProgressLengthSpoolConverter.cs" /> <Compile Include="Converters\TimeSpanHumanizeConverter.cs" /> <Compile Include="Converters\TotalDyeTimeConverter.cs" /> <Compile Include="Converters\TotalMetersConverter.cs" /> @@ -380,6 +384,18 @@ <SubType>Designer</SubType> <Generator>MSBuild:Compile</Generator> </Page> + <Page Include="Controls\MachineConnectionIcon.xaml"> + <SubType>Designer</SubType> + <Generator>MSBuild:Compile</Generator> + </Page> + <Page Include="Controls\MachineIcon.xaml"> + <SubType>Designer</SubType> + <Generator>MSBuild:Compile</Generator> + </Page> + <Page Include="Controls\MachineIconFull.xaml"> + <SubType>Designer</SubType> + <Generator>MSBuild:Compile</Generator> + </Page> <Page Include="Controls\MachineView.xaml"> <Generator>MSBuild:Compile</Generator> <SubType>Designer</SubType> @@ -670,7 +686,36 @@ <Resource Include="Images\shadow_right.png" /> <Resource Include="Images\shadow_top.png" /> </ItemGroup> - <ItemGroup /> + <ItemGroup> + <Resource Include="Images\Connections\emulator.png" /> + </ItemGroup> + <ItemGroup> + <Resource Include="Images\Connections\signalr.png" /> + </ItemGroup> + <ItemGroup> + <Resource Include="Images\Connections\tcp.png" /> + </ItemGroup> + <ItemGroup> + <Resource Include="Images\Connections\ts1800.png" /> + </ItemGroup> + <ItemGroup> + <Resource Include="Images\Connections\usb.png" /> + </ItemGroup> + <ItemGroup> + <Resource Include="Images\Connections\wifi.png" /> + </ItemGroup> + <ItemGroup> + <Resource Include="Images\Connections\eureka.png" /> + </ItemGroup> + <ItemGroup> + <Resource Include="Images\eureka_full.png" /> + </ItemGroup> + <ItemGroup> + <Resource Include="Images\eureka_small.png" /> + </ItemGroup> + <ItemGroup> + <Resource Include="Images\machines.png" /> + </ItemGroup> <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" /> <PropertyGroup> <PreBuildEvent> diff --git a/Software/Visual_Studio/FSE/Tango.FSE.Common/Themes/Generic.xaml b/Software/Visual_Studio/FSE/Tango.FSE.Common/Themes/Generic.xaml index 9b1bd93cf..994dfc6ba 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.Common/Themes/Generic.xaml +++ b/Software/Visual_Studio/FSE/Tango.FSE.Common/Themes/Generic.xaml @@ -3,5 +3,6 @@ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:local="clr-namespace:Tango.FSE.Common"> + </ResourceDictionary> diff --git a/Software/Visual_Studio/FSE/Tango.FSE.UI/BugReporting/DefaultBugReporter.cs b/Software/Visual_Studio/FSE/Tango.FSE.UI/BugReporting/DefaultBugReporter.cs index 2f4d75b37..e902bfded 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.UI/BugReporting/DefaultBugReporter.cs +++ b/Software/Visual_Studio/FSE/Tango.FSE.UI/BugReporting/DefaultBugReporter.cs @@ -162,6 +162,7 @@ namespace Tango.FSE.UI.BugReporting item.State = State.New; item.Type = WorkItemType.Bug; item.Environment = AuthenticationProvider.CurrentEnvironment.Description; + item.MachineType = (MachineType)Settings.LastConnectedMachineType; bool hasPPCLogs = false; bool hasFirmwareLogs = false; diff --git a/Software/Visual_Studio/FSE/Tango.FSE.UI/Connection/DefaultMachineProvider.cs b/Software/Visual_Studio/FSE/Tango.FSE.UI/Connection/DefaultMachineProvider.cs index cf4337508..aee4613d4 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.UI/Connection/DefaultMachineProvider.cs +++ b/Software/Visual_Studio/FSE/Tango.FSE.UI/Connection/DefaultMachineProvider.cs @@ -203,11 +203,11 @@ namespace Tango.FSE.UI.Connection if (machine.GetType() == typeof(ExternalBridgeUsbClient)) { - vm = await NotificationProvider.ShowDialog<MachineConnectionUsbViewVM>(); + vm = await NotificationProvider.ShowDialog(new MachineConnectionUsbViewVM() { Machine = machine }); } else if (machine.GetType() == typeof(EmulatorExternalBridge)) { - vm = await NotificationProvider.ShowDialog<MachineConnectionEmulatorViewVM>(); + vm = await NotificationProvider.ShowDialog(new MachineConnectionEmulatorViewVM() { Machine = machine }); } else if (machine is ExternalBridgeTcpClient) { @@ -566,6 +566,8 @@ namespace Tango.FSE.UI.Connection protected virtual void OnMachineConnected(IExternalBridgeClient machineOperator) { + Settings.LastConnectedMachineType = (int)machineOperator.MachineType; + MachineConnected?.Invoke(this, new MachineConnectedEventArgs() { MachineOperator = machineOperator, diff --git a/Software/Visual_Studio/FSE/Tango.FSE.UI/Converters/MidTankLevelToElementHeightConverter.cs b/Software/Visual_Studio/FSE/Tango.FSE.UI/Converters/MidTankLevelToElementHeightConverter.cs index 88a90484d..f96725816 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.UI/Converters/MidTankLevelToElementHeightConverter.cs +++ b/Software/Visual_Studio/FSE/Tango.FSE.UI/Converters/MidTankLevelToElementHeightConverter.cs @@ -16,9 +16,9 @@ namespace Tango.FSE.UI.Converters try { double parentActualHeight = (double)values[0]; - double midTankLevel = Math.Min((double)values[1], MachineOperator.MAX_MIDTANK_LITERS); - //var test = (parentActualHeight - (midTankLevel / MachineOperator.MAX_MIDTANK_LITERS) * parentActualHeight); - return (parentActualHeight - (midTankLevel / MachineOperator.MAX_MIDTANK_LITERS) * parentActualHeight); + double max = (double)values[2]; + double midTankLevel = Math.Min((double)values[1], max); + return (parentActualHeight - (midTankLevel / max) * parentActualHeight); } catch { diff --git a/Software/Visual_Studio/FSE/Tango.FSE.UI/Dialogs/MachineConnectionEmulatorView.xaml b/Software/Visual_Studio/FSE/Tango.FSE.UI/Dialogs/MachineConnectionEmulatorView.xaml index 45be0817b..0e78e8b55 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.UI/Dialogs/MachineConnectionEmulatorView.xaml +++ b/Software/Visual_Studio/FSE/Tango.FSE.UI/Dialogs/MachineConnectionEmulatorView.xaml @@ -5,13 +5,14 @@ xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:autoComplete="clr-namespace:Tango.AutoComplete.Editors;assembly=Tango.AutoComplete" xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes" + xmlns:controls="clr-namespace:Tango.FSE.Common.Controls;assembly=Tango.FSE.Common" xmlns:local="clr-namespace:Tango.FSE.UI.Dialogs" mc:Ignorable="d" Height="300" Width="700" d:DataContext="{d:DesignInstance Type=local:MachineConnectionEmulatorViewVM, IsDesignTimeCreatable=False}" Background="{StaticResource FSE_PrimaryBackgroundLightBrush}" Foreground="{StaticResource FSE_PrimaryForegroundBrush}"> <Grid> <DockPanel Margin="10"> <StackPanel DockPanel.Dock="Top" Orientation="Horizontal" Margin="10"> - <ContentControl Height="60" Margin="-10 0 0 0" Style="{StaticResource FSE_EmulatorMachineIcon}"></ContentControl> + <controls:MachineConnectionIcon ExternalBridgeClient="{Binding Machine}" Height="60" Margin="-10 0 0 0"></controls:MachineConnectionIcon> <TextBlock Text="Machine Selection" FontWeight="SemiBold" VerticalAlignment="Center" Margin="10 0 0 0" FontSize="{StaticResource FSE_MessageBoxTitleFontSize}"></TextBlock> </StackPanel> diff --git a/Software/Visual_Studio/FSE/Tango.FSE.UI/Dialogs/MachineConnectionLostView.xaml b/Software/Visual_Studio/FSE/Tango.FSE.UI/Dialogs/MachineConnectionLostView.xaml index 06617885a..26fca9093 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.UI/Dialogs/MachineConnectionLostView.xaml +++ b/Software/Visual_Studio/FSE/Tango.FSE.UI/Dialogs/MachineConnectionLostView.xaml @@ -5,17 +5,18 @@ xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:material="http://materialdesigninxaml.net/winfx/xaml/themes" xmlns:local="clr-namespace:Tango.FSE.UI.Dialogs" + xmlns:controls="clr-namespace:Tango.FSE.Common.Controls;assembly=Tango.FSE.Common" mc:Ignorable="d" Height="300" Width="700" d:DataContext="{d:DesignInstance Type=local:MachineConnectionLostViewVM, IsDesignTimeCreatable=False}" Background="{StaticResource FSE_PrimaryBackgroundLightBrush}" Foreground="{StaticResource FSE_PrimaryForegroundBrush}"> <Grid> <DockPanel Margin="10"> <StackPanel DockPanel.Dock="Top" Orientation="Horizontal" Margin="10"> <Grid> - <ContentControl Height="60" Margin="-10 0 0 0" Style="{StaticResource FSE_WifiMachineIcon}"> - <ContentControl.Effect> + <controls:MachineConnectionIcon ExternalBridgeClient="{Binding Machine}" Height="60" Margin="-10 0 0 0"> + <controls:MachineConnectionIcon.Effect> <BlurEffect Radius="5" /> - </ContentControl.Effect> - </ContentControl> + </controls:MachineConnectionIcon.Effect> + </controls:MachineConnectionIcon> <Canvas> <material:PackIcon Kind="Exclamation" Foreground="{StaticResource FSE_ErrorBrush}" Width="45" Height="45" Margin="-5 13 0 0" /> </Canvas> diff --git a/Software/Visual_Studio/FSE/Tango.FSE.UI/Dialogs/MachineConnectionSignalRView.xaml b/Software/Visual_Studio/FSE/Tango.FSE.UI/Dialogs/MachineConnectionSignalRView.xaml index b091516df..43f32d820 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.UI/Dialogs/MachineConnectionSignalRView.xaml +++ b/Software/Visual_Studio/FSE/Tango.FSE.UI/Dialogs/MachineConnectionSignalRView.xaml @@ -6,13 +6,14 @@ xmlns:autoComplete="clr-namespace:Tango.AutoComplete.Editors;assembly=Tango.AutoComplete" xmlns:helpers="clr-namespace:Tango.SharedUI.Helpers;assembly=Tango.SharedUI" xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes" + xmlns:controls="clr-namespace:Tango.FSE.Common.Controls;assembly=Tango.FSE.Common" xmlns:local="clr-namespace:Tango.FSE.UI.Dialogs" mc:Ignorable="d" Height="300" Width="700" d:DataContext="{d:DesignInstance Type=local:MachineConnectionSignalRViewVM, IsDesignTimeCreatable=False}" Background="{StaticResource FSE_PrimaryBackgroundLightBrush}" Foreground="{StaticResource FSE_PrimaryForegroundBrush}"> <Grid> <DockPanel Margin="10"> <StackPanel DockPanel.Dock="Top" Orientation="Horizontal" Margin="10"> - <ContentControl Height="60" Margin="-10 0 0 0" Style="{StaticResource FSE_SignalRMachineIcon}"></ContentControl> + <controls:MachineConnectionIcon ExternalBridgeClient="{Binding Machine}" Height="60" Margin="-10 0 0 0"></controls:MachineConnectionIcon> <TextBlock FontWeight="SemiBold" VerticalAlignment="Center" Margin="10 0 0 0" FontSize="{StaticResource FSE_MessageBoxTitleFontSize}"> <Run>Connect to</Run> <Run>'</Run><Run FontWeight="Normal" Foreground="{StaticResource FSE_SignalRBrush}" Text="{Binding Machine.SerialNumber}"></Run><Run>'</Run> diff --git a/Software/Visual_Studio/FSE/Tango.FSE.UI/Dialogs/MachineConnectionUsbView.xaml b/Software/Visual_Studio/FSE/Tango.FSE.UI/Dialogs/MachineConnectionUsbView.xaml index 6ab2414f3..c285d2ed6 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.UI/Dialogs/MachineConnectionUsbView.xaml +++ b/Software/Visual_Studio/FSE/Tango.FSE.UI/Dialogs/MachineConnectionUsbView.xaml @@ -5,13 +5,14 @@ xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:autoComplete="clr-namespace:Tango.AutoComplete.Editors;assembly=Tango.AutoComplete" xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes" + xmlns:controls="clr-namespace:Tango.FSE.Common.Controls;assembly=Tango.FSE.Common" xmlns:local="clr-namespace:Tango.FSE.UI.Dialogs" mc:Ignorable="d" Height="300" Width="700" d:DataContext="{d:DesignInstance Type=local:MachineConnectionUsbViewVM, IsDesignTimeCreatable=False}" Background="{StaticResource FSE_PrimaryBackgroundLightBrush}" Foreground="{StaticResource FSE_PrimaryForegroundBrush}"> <Grid> <DockPanel Margin="10"> <StackPanel DockPanel.Dock="Top" Orientation="Horizontal" Margin="10"> - <ContentControl Height="60" Margin="-10 0 0 0" Style="{StaticResource FSE_UsbMachineIcon}"></ContentControl> + <controls:MachineConnectionIcon ExternalBridgeClient="{Binding Machine}" Height="60" Margin="-10 0 0 0"></controls:MachineConnectionIcon> <TextBlock Text="Machine Selection" FontWeight="SemiBold" VerticalAlignment="Center" Margin="10 0 0 0" FontSize="{StaticResource FSE_MessageBoxTitleFontSize}"></TextBlock> </StackPanel> diff --git a/Software/Visual_Studio/FSE/Tango.FSE.UI/Dialogs/MachineConnectionUsbViewVM.cs b/Software/Visual_Studio/FSE/Tango.FSE.UI/Dialogs/MachineConnectionUsbViewVM.cs index e881da0ac..9056e7f4d 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.UI/Dialogs/MachineConnectionUsbViewVM.cs +++ b/Software/Visual_Studio/FSE/Tango.FSE.UI/Dialogs/MachineConnectionUsbViewVM.cs @@ -10,6 +10,7 @@ using Tango.Core.DI; using Tango.FSE.BL; using Tango.FSE.Common; using Tango.FSE.Common.AutoComplete; +using Tango.Integration.ExternalBridge; namespace Tango.FSE.UI.Dialogs { @@ -22,6 +23,8 @@ namespace Tango.FSE.UI.Dialogs [TangoInject] protected FSEServicesContainer Services { get; set; } + public IExternalBridgeClient Machine { get; set; } + /// <summary> /// Gets or sets the machines completion source. /// </summary> diff --git a/Software/Visual_Studio/FSE/Tango.FSE.UI/Dialogs/MachineConnectionWifiView.xaml b/Software/Visual_Studio/FSE/Tango.FSE.UI/Dialogs/MachineConnectionWifiView.xaml index 5d9a5f74f..c1fd6fa7c 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.UI/Dialogs/MachineConnectionWifiView.xaml +++ b/Software/Visual_Studio/FSE/Tango.FSE.UI/Dialogs/MachineConnectionWifiView.xaml @@ -3,6 +3,7 @@ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" + xmlns:controls="clr-namespace:Tango.FSE.Common.Controls;assembly=Tango.FSE.Common" xmlns:autoComplete="clr-namespace:Tango.AutoComplete.Editors;assembly=Tango.AutoComplete" xmlns:helpers="clr-namespace:Tango.SharedUI.Helpers;assembly=Tango.SharedUI" xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes" @@ -12,7 +13,7 @@ <Grid> <DockPanel Margin="10"> <StackPanel DockPanel.Dock="Top" Orientation="Horizontal" Margin="10"> - <ContentControl Height="60" Margin="-10 0 0 0" Style="{StaticResource FSE_WifiMachineIcon}"></ContentControl> + <controls:MachineConnectionIcon ExternalBridgeClient="{Binding Machine}" Height="60" Margin="-10 0 0 0"></controls:MachineConnectionIcon> <TextBlock FontWeight="SemiBold" VerticalAlignment="Center" Margin="10 0 0 0" FontSize="{StaticResource FSE_MessageBoxTitleFontSize}"> <Run>Connect to</Run> <Run>'</Run><Run FontWeight="Normal" Foreground="{StaticResource FSE_WifiBrush}" Text="{Binding Machine.SerialNumber}"></Run><Run>'</Run> diff --git a/Software/Visual_Studio/FSE/Tango.FSE.UI/Dialogs/MachineWaitForConnectionView.xaml b/Software/Visual_Studio/FSE/Tango.FSE.UI/Dialogs/MachineWaitForConnectionView.xaml index 946e2bf0d..1d9359b04 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.UI/Dialogs/MachineWaitForConnectionView.xaml +++ b/Software/Visual_Studio/FSE/Tango.FSE.UI/Dialogs/MachineWaitForConnectionView.xaml @@ -4,6 +4,7 @@ xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:material="http://materialdesigninxaml.net/winfx/xaml/themes" + xmlns:controls="clr-namespace:Tango.FSE.Common.Controls;assembly=Tango.FSE.Common" xmlns:local="clr-namespace:Tango.FSE.UI.Dialogs" mc:Ignorable="d" Height="300" Width="700" d:DataContext="{d:DesignInstance Type=local:MachineWaitForConnectionViewVM, IsDesignTimeCreatable=False}" Background="{StaticResource FSE_PrimaryBackgroundLightBrush}" Foreground="{StaticResource FSE_PrimaryForegroundBrush}"> @@ -11,11 +12,11 @@ <DockPanel Margin="10"> <StackPanel DockPanel.Dock="Top" Orientation="Horizontal" Margin="10"> <Grid> - <ContentControl Height="60" Margin="-10 0 0 0" Style="{StaticResource FSE_WifiMachineIcon}"> - <ContentControl.Effect> + <controls:MachineConnectionIcon ExternalBridgeClient="{Binding Machine}" Height="60" Margin="-10 0 0 0"> + <controls:MachineConnectionIcon.Effect> <BlurEffect Radius="5" /> - </ContentControl.Effect> - </ContentControl> + </controls:MachineConnectionIcon.Effect> + </controls:MachineConnectionIcon> <Canvas> <ProgressBar Style="{StaticResource FSE_CircularProgressBar}" Foreground="{StaticResource FSE_GrayBrush}" Opacity="0.5" Width="24" Height="24" Margin="5 24 0 0" /> </Canvas> diff --git a/Software/Visual_Studio/FSE/Tango.FSE.UI/Panes/MachineConnectionPane.xaml b/Software/Visual_Studio/FSE/Tango.FSE.UI/Panes/MachineConnectionPane.xaml index b4b70cffd..1c6668e2a 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.UI/Panes/MachineConnectionPane.xaml +++ b/Software/Visual_Studio/FSE/Tango.FSE.UI/Panes/MachineConnectionPane.xaml @@ -5,6 +5,7 @@ xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:material="http://materialdesigninxaml.net/winfx/xaml/themes" xmlns:local="clr-namespace:Tango.FSE.UI.Panes" + xmlns:controls="clr-namespace:Tango.FSE.Common.Controls;assembly=Tango.FSE.Common" mc:Ignorable="d" d:DesignHeight="600" d:DesignWidth="350" d:DataContext="{d:DesignInstance Type=local:MachineConnectionPaneVM, IsDesignTimeCreatable=False}"> <Grid> @@ -34,7 +35,7 @@ <ListBox.ItemTemplate> <DataTemplate> <StackPanel Orientation="Horizontal"> - <ContentControl Style="{StaticResource FSE_EmulatorMachineIcon}" Height="35"></ContentControl> + <controls:MachineConnectionIcon ExternalBridgeClient="{Binding}" Height="35"></controls:MachineConnectionIcon> <StackPanel Margin="10 0 0 0"> <TextBlock FontSize="{StaticResource FSE_SmallFontSize}" FontWeight="SemiBold">In-Memory Emulator</TextBlock> <TextBlock FontSize="{StaticResource FSE_SmallFontSize}"> @@ -55,7 +56,7 @@ <ListBox.ItemTemplate> <DataTemplate> <StackPanel Orientation="Horizontal"> - <ContentControl Style="{StaticResource FSE_UsbMachineIcon}" Height="35"></ContentControl> + <controls:MachineConnectionIcon ExternalBridgeClient="{Binding}" Height="35"></controls:MachineConnectionIcon> <StackPanel Margin="10 0 0 0"> <TextBlock FontSize="{StaticResource FSE_SmallFontSize}"> <Run FontWeight="SemiBold">Port:</Run> <Run Text="{Binding ComPort,Mode=OneWay}"></Run> @@ -90,7 +91,7 @@ <ListBox.ItemTemplate> <DataTemplate> <StackPanel Orientation="Horizontal"> - <ContentControl Style="{StaticResource FSE_WifiMachineIcon}" /> + <controls:MachineConnectionIcon ExternalBridgeClient="{Binding}" Height="35"></controls:MachineConnectionIcon> <StackPanel Margin="10 0 0 0"> <TextBlock FontSize="{StaticResource FSE_SmallFontSize}"> <Run FontWeight="SemiBold">S/N:</Run> <Run Text="{Binding SerialNumber,Mode=OneWay}"></Run> @@ -117,7 +118,7 @@ <ListBox.ItemTemplate> <DataTemplate> <StackPanel Orientation="Horizontal"> - <ContentControl Style="{StaticResource FSE_SignalRMachineIcon}" /> + <controls:MachineConnectionIcon ExternalBridgeClient="{Binding}" Height="35"></controls:MachineConnectionIcon> <StackPanel Margin="10 0 0 0"> <TextBlock FontSize="{StaticResource FSE_SmallFontSize}"> <Run FontWeight="Bold">S/N:</Run> <Run Text="{Binding SerialNumber,Mode=OneWay}"></Run> diff --git a/Software/Visual_Studio/FSE/Tango.FSE.UI/Properties/AssemblyInfo.cs b/Software/Visual_Studio/FSE/Tango.FSE.UI/Properties/AssemblyInfo.cs index ccb936fc4..f13bd3e02 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.UI/Properties/AssemblyInfo.cs +++ b/Software/Visual_Studio/FSE/Tango.FSE.UI/Properties/AssemblyInfo.cs @@ -8,4 +8,4 @@ using System.Windows; // set of attributes. Change these attribute values to modify the information // associated with an assembly. [assembly: AssemblyTitle("Tango FSE")] -[assembly: AssemblyVersion("1.4.7.0")] +[assembly: AssemblyVersion("2.0.2.0")] diff --git a/Software/Visual_Studio/FSE/Tango.FSE.UI/Tiles/Machine/MachineTile.cs b/Software/Visual_Studio/FSE/Tango.FSE.UI/Tiles/Machine/MachineTile.cs index 611c4d93e..45265c636 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.UI/Tiles/Machine/MachineTile.cs +++ b/Software/Visual_Studio/FSE/Tango.FSE.UI/Tiles/Machine/MachineTile.cs @@ -5,11 +5,19 @@ using System.Text; using System.Threading.Tasks; using System.Windows; using Tango.FSE.Common; +using Tango.FSE.Common.Connection; namespace Tango.FSE.UI.Tiles.Machine { public class MachineTile : DashboardTile { + private Tango.BL.Entities.Machine _machine; + public Tango.BL.Entities.Machine Machine + { + get { return _machine; } + set { _machine = value; RaisePropertyChangedAuto(); } + } + public MachineTile() { Name = "Machine Configuration"; @@ -21,6 +29,18 @@ namespace Tango.FSE.UI.Tiles.Machine RowSpan = 6; } + public override void OnApplicationReady() + { + base.OnApplicationReady(); + + MachineProvider.MachineConnected += MachineProvider_MachineConnected; + } + + private void MachineProvider_MachineConnected(object sender, MachineConnectedEventArgs e) + { + Machine = MachineProvider.Machine; + } + public override FrameworkElement GetView() { return new MachineTileView(); diff --git a/Software/Visual_Studio/FSE/Tango.FSE.UI/Tiles/Machine/MachineTileView.xaml b/Software/Visual_Studio/FSE/Tango.FSE.UI/Tiles/Machine/MachineTileView.xaml index 625f0df7d..9f1d7bd30 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.UI/Tiles/Machine/MachineTileView.xaml +++ b/Software/Visual_Studio/FSE/Tango.FSE.UI/Tiles/Machine/MachineTileView.xaml @@ -8,6 +8,6 @@ mc:Ignorable="d" d:DesignHeight="450" d:DesignWidth="800" d:DataContext="{d:DesignInstance Type=local:MachineTile, IsDesignTimeCreatable=False}"> <Grid Margin="20"> - <controls:MachineView Opacity="0.6" DataContext="{Binding MachineProvider.Machine}" /> + <controls:MachineView Opacity="0.6" DataContext="{Binding Machine}" /> </Grid> </UserControl> diff --git a/Software/Visual_Studio/FSE/Tango.FSE.UI/Tiles/MidTankLevels/MidTankLevelsTile.cs b/Software/Visual_Studio/FSE/Tango.FSE.UI/Tiles/MidTankLevels/MidTankLevelsTile.cs index d8165d8aa..730055872 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.UI/Tiles/MidTankLevels/MidTankLevelsTile.cs +++ b/Software/Visual_Studio/FSE/Tango.FSE.UI/Tiles/MidTankLevels/MidTankLevelsTile.cs @@ -142,7 +142,7 @@ namespace Tango.FSE.UI.Tiles.MidTankLevels { MidTankLevels = MachineProvider.Machine.Configuration.NoneEmptyIdsPacks.Where(x => x.MidTankType.HasLevelMeasure).OrderBy(x => x.PackIndex).Select(x => new MidTankLevelModel() { - Max = MachineOperator.MAX_MIDTANK_LITERS, + Max = x.MidTankType.LiterCapacity, IDSPack = x, }).ToList(); } diff --git a/Software/Visual_Studio/FSE/Tango.FSE.UI/Tiles/MidTankLevels/MidTankLevelsTileView.xaml b/Software/Visual_Studio/FSE/Tango.FSE.UI/Tiles/MidTankLevels/MidTankLevelsTileView.xaml index 7465f41c0..5e4f8ed9a 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.UI/Tiles/MidTankLevels/MidTankLevelsTileView.xaml +++ b/Software/Visual_Studio/FSE/Tango.FSE.UI/Tiles/MidTankLevels/MidTankLevelsTileView.xaml @@ -58,6 +58,7 @@ <MultiBinding Converter="{StaticResource MidTankLevelToElementHeightConverter}"> <Binding ElementName="pathBorder" Path="ActualHeight" /> <Binding Path="Level" /> + <Binding Path="Max" /> </MultiBinding> </Setter.Value> </Setter> diff --git a/Software/Visual_Studio/FSE/Tango.FSE.UI/Tiles/RemoteJob/RemoteJobProgressRingTileView.xaml b/Software/Visual_Studio/FSE/Tango.FSE.UI/Tiles/RemoteJob/RemoteJobProgressRingTileView.xaml index 62e7c4798..c021b0a15 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.UI/Tiles/RemoteJob/RemoteJobProgressRingTileView.xaml +++ b/Software/Visual_Studio/FSE/Tango.FSE.UI/Tiles/RemoteJob/RemoteJobProgressRingTileView.xaml @@ -9,6 +9,6 @@ mc:Ignorable="d" d:DesignHeight="450" d:DesignWidth="800" d:DataContext="{d:DesignInstance Type=local:RemoteJobProgressRingTile, IsDesignTimeCreatable=False}"> <Grid Margin="30"> - <controls:RunningJobRingProgress RunningJobStatus="{Binding RunningJobStatus}" IsRunning="{Binding IsRunning}" /> + <controls:RunningJobRingProgress RunningJobStatus="{Binding RunningJobStatus}" IsRunning="{Binding IsRunning}" IsEureka ="{Binding IsEureka}" /> </Grid> </UserControl> diff --git a/Software/Visual_Studio/FSE/Tango.FSE.UI/Tiles/RemoteJob/RemoteJobTile.cs b/Software/Visual_Studio/FSE/Tango.FSE.UI/Tiles/RemoteJob/RemoteJobTile.cs index 650818c22..453a0892e 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.UI/Tiles/RemoteJob/RemoteJobTile.cs +++ b/Software/Visual_Studio/FSE/Tango.FSE.UI/Tiles/RemoteJob/RemoteJobTile.cs @@ -6,6 +6,7 @@ using System.Threading.Tasks; using System.Windows; using System.Windows.Media; using Tango.BL.Entities; +using Tango.BL.Enumerations; using Tango.FSE.Common; using Tango.Integration.Operation; using Tango.PPC.Shared.Jobs; @@ -42,6 +43,15 @@ namespace Tango.FSE.UI.Tiles.RemoteJob set { _isRunning = value; RaisePropertyChangedAuto(); } } + private bool _isEureka; + + public bool IsEureka + { + get { return _isEureka; } + set { _isEureka = value; RaisePropertyChangedAuto(); } + } + + public RemoteJobTile() { Name = "Remote Job"; @@ -113,6 +123,7 @@ namespace Tango.FSE.UI.Tiles.RemoteJob Handler.StatusChanged += Handler_StatusChanged; Job = e.JobHandler.Job; IsRunning = true; + IsEureka = MachineProvider.MachineOperator.MachineType == MachineTypes.Eureka; } private void Handler_StatusChanged(object sender, RunningJobStatus status) diff --git a/Software/Visual_Studio/FSE/Tango.FSE.UI/Tiles/RemoteJob/RemoteJobTileView.xaml b/Software/Visual_Studio/FSE/Tango.FSE.UI/Tiles/RemoteJob/RemoteJobTileView.xaml index ee05314ce..1323c9298 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.UI/Tiles/RemoteJob/RemoteJobTileView.xaml +++ b/Software/Visual_Studio/FSE/Tango.FSE.UI/Tiles/RemoteJob/RemoteJobTileView.xaml @@ -10,7 +10,7 @@ <Grid TextElement.Foreground="{StaticResource FSE_PrimaryAccentBrush}"> <Viewbox Width="{Binding RelativeSource={RelativeSource AncestorType=UserControl},Path=ActualWidth}"> <Border Background="#292929" CornerRadius="10" VerticalAlignment="Bottom" Padding="20 0" Width="{Binding RelativeSource={RelativeSource AncestorType=UserControl},Path=ActualWidth}"> - <controls:RunningJobViewer IsRunning="{Binding IsRunning}" Job="{Binding Job}" RunningJobStatus="{Binding RunningJobStatus}" IsActive="True" Margin="30 10" Height="90" /> + <controls:RunningJobViewer IsRunning="{Binding IsRunning}" Job="{Binding Job}" RunningJobStatus="{Binding RunningJobStatus}" IsEureka="{Binding IsEureka}" IsActive="True" Margin="30 10" Height="90" /> </Border> </Viewbox> </Grid> diff --git a/Software/Visual_Studio/FSE/Tango.FSE.UI/Views/LayoutView.xaml b/Software/Visual_Studio/FSE/Tango.FSE.UI/Views/LayoutView.xaml index b897851fc..f1ed89aff 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.UI/Views/LayoutView.xaml +++ b/Software/Visual_Studio/FSE/Tango.FSE.UI/Views/LayoutView.xaml @@ -548,7 +548,7 @@ <Grid Panel.ZIndex="100"> <DockPanel> - <Image x:Name="imgHome" RenderTransformOrigin="0.5,0.5" Cursor="Hand" Source="{StaticResource FSE_Machine_Full}" Stretch="Uniform" RenderOptions.BitmapScalingMode="Fant" Margin="10"> + <Image x:Name="imgHome" RenderTransformOrigin="0.5,0.5" Cursor="Hand" Source="{StaticResource FSE_Machines_Full}" Stretch="Uniform" RenderOptions.BitmapScalingMode="Fant" Margin="10"> <i:Interaction.Triggers> <i:EventTrigger EventName="PreviewMouseUp"> <i:InvokeCommandAction Command="{Binding NavigateHomeCommand}" /> diff --git a/Software/Visual_Studio/FSE/Tango.FSE.UI/Views/LoginView.xaml b/Software/Visual_Studio/FSE/Tango.FSE.UI/Views/LoginView.xaml index 0ab9c5018..ca56e7b05 100644 --- a/Software/Visual_Studio/FSE/Tango.FSE.UI/Views/LoginView.xaml +++ b/Software/Visual_Studio/FSE/Tango.FSE.UI/Views/LoginView.xaml @@ -50,7 +50,7 @@ <Run FontSize="10">v</Run><Run Text="{Binding ApplicationVersion,Mode=OneWay,FallbackValue='1.0.0'}"></Run> </TextBlock> </StackPanel> - <Image Source="{StaticResource FSE_Machine_Full}" VerticalAlignment="Bottom" RenderOptions.BitmapScalingMode="Fant" Margin="0 0 0 150" MaxWidth="300" MinWidth="100" /> + <Image Source="{StaticResource FSE_Machines_Full}" VerticalAlignment="Bottom" RenderOptions.BitmapScalingMode="Fant" Margin="0 0 0 150" MaxWidth="300" MinWidth="100" /> <Rectangle HorizontalAlignment="Right" StrokeThickness="1" Stroke="{StaticResource FSE_BorderBrush}" StrokeDashArray="5" /> </Grid> |
