aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer
diff options
context:
space:
mode:
authorAvi Levkovich <avi@twine-s.com>2020-12-30 18:11:26 +0200
committerAvi Levkovich <avi@twine-s.com>2020-12-30 18:11:26 +0200
commit71e6a3ec2197eba8b5e1b295914653426064f745 (patch)
treec97ef7e44c7c41a5d31e48120bc5e5770b35ac48 /Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer
parent325242bcd9ccbc97bb14b4ca91d01fc7bd999739 (diff)
parente00d02878767964604cd02fb98c58be6bc3a02af (diff)
downloadTango-71e6a3ec2197eba8b5e1b295914653426064f745.tar.gz
Tango-71e6a3ec2197eba8b5e1b295914653426064f745.zip
Merge branch 'master' of https://twinetfs.visualstudio.com/_git/Tango
Diffstat (limited to 'Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer')
-rw-r--r--Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Controls/JobSummeryViewer.xaml131
-rw-r--r--Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Controls/JobSummeryViewer.xaml.cs56
-rw-r--r--Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Tango.MachineStudio.Developer.csproj9
-rw-r--r--Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/ViewModels/MainViewVM.cs13
-rw-r--r--Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Views/JobView.xaml74
-rw-r--r--Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Views/JobView.xaml.cs42
6 files changed, 98 insertions, 227 deletions
diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Controls/JobSummeryViewer.xaml b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Controls/JobSummeryViewer.xaml
deleted file mode 100644
index eeb25dc83..000000000
--- a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Controls/JobSummeryViewer.xaml
+++ /dev/null
@@ -1,131 +0,0 @@
-<UserControl x:Class="Tango.MachineStudio.Developer.Controls.JobSummeryViewer"
- xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
- 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:enumerations="clr-namespace:Tango.BL.Enumerations;assembly=Tango.BL"
- xmlns:converters="clr-namespace:Tango.SharedUI.Converters;assembly=Tango.SharedUI"
- xmlns:entities="clr-namespace:Tango.BL.Entities;assembly=Tango.BL"
- xmlns:local="clr-namespace:Tango.MachineStudio.Developer.Controls"
- mc:Ignorable="d"
- d:DesignHeight="60" d:DesignWidth="500" Height="38" d:DataContext="{d:DesignInstance Type=entities:Job, IsDesignTimeCreatable=False}" x:Name="control">
-
- <UserControl.Resources>
- <converters:BooleanToVisibilityConverter x:Key="BooleanToVisibilityConverter" />
- <converters:SegmentLengthToWidthConverter x:Key="SegmentLengthToWidthConverter" />
- <converters:SmallerThanToBooleanConverter x:Key="SmallerThanToBooleanConverter" />
- <converters:WidthHeightToRectConverter x:Key="WidthHeightToRectConverter" />
-
- </UserControl.Resources>
-
-
- <Grid>
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="1*"/>
- <ColumnDefinition Width="Auto"/>
- </Grid.ColumnDefinitions>
- <Grid>
- <Grid.RowDefinitions>
- <RowDefinition Height="Auto" />
- <RowDefinition Height="1*" />
- </Grid.RowDefinitions>
-
- <ItemsControl ClipToBounds="False" ItemsSource="{Binding EffectiveSegments,IsAsync=True}" Visibility="{Binding RelativeSource={RelativeSource AncestorType=UserControl},Path=DisplayMarkers,Converter={StaticResource BooleanToVisibilityConverter}}">
- <ItemsControl.ItemsPanel>
- <ItemsPanelTemplate>
- <StackPanel Orientation="Horizontal" ClipToBounds="False"></StackPanel>
- </ItemsPanelTemplate>
- </ItemsControl.ItemsPanel>
- <ItemsControl.ItemTemplate>
- <DataTemplate>
- <Grid x:Name="grid">
- <Grid.Width>
- <MultiBinding Converter="{StaticResource SegmentLengthToWidthConverter}">
- <Binding RelativeSource="{RelativeSource AncestorType=UserControl}" Path="DataContext.Length"></Binding>
- <Binding RelativeSource="{RelativeSource AncestorType=ItemsControl}" Path="ActualWidth"></Binding>
- <Binding Path="LengthWithFactor"></Binding>
- </MultiBinding>
- </Grid.Width>
-
- <TextBlock HorizontalAlignment="Center" FontSize="10">
- <TextBlock.Style>
- <Style TargetType="TextBlock">
- <Setter Property="Visibility" Value="Visible"></Setter>
- <Style.Triggers>
- <DataTrigger Binding="{Binding ElementName=grid,Path=ActualWidth,Converter={StaticResource SmallerThanToBooleanConverter},ConverterParameter=20}" Value="True">
- <Setter Property="Visibility" Value="Collapsed"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </TextBlock.Style>
- <Run Text="{Binding LengthWithFactor,Mode=OneWay,StringFormat=N0,IsAsync=True}"></Run><Run Text="m"></Run>
- </TextBlock>
- </Grid>
- </DataTemplate>
- </ItemsControl.ItemTemplate>
- </ItemsControl>
-
- <Border Grid.Row="1" x:Name="brush_border" ClipToBounds="False" CornerRadius="10" Margin="0 5 0 0">
- <Border.Clip>
- <RectangleGeometry RadiusX="10" RadiusY="10">
- <RectangleGeometry.Rect>
- <MultiBinding Converter="{StaticResource WidthHeightToRectConverter}">
- <Binding ElementName="brush_border" Path="ActualWidth" />
- <Binding ElementName="brush_border" Path="ActualHeight" />
- </MultiBinding>
- </RectangleGeometry.Rect>
- </RectangleGeometry>
- </Border.Clip>
- <!--<Border.Background>
- --><!--<ImageBrush ImageSource="../Images/JobView/transparent_small.jpg" Stretch="None" TileMode="Tile" AlignmentX="Left" ViewportUnits="Absolute" Viewport="0,0,94,30" />--><!--
- </Border.Background>-->
- <Grid>
- <ItemsControl ClipToBounds="False" ItemsSource="{Binding EffectiveSegments,IsAsync=True}">
- <ItemsControl.ItemsPanel>
- <ItemsPanelTemplate>
- <StackPanel Orientation="Horizontal" ClipToBounds="False"></StackPanel>
- </ItemsPanelTemplate>
- </ItemsControl.ItemsPanel>
- <ItemsControl.ItemTemplate>
- <DataTemplate>
- <Grid>
- <Grid.Width>
- <MultiBinding Converter="{StaticResource SegmentLengthToWidthConverter}">
- <Binding RelativeSource="{RelativeSource AncestorType=UserControl}" Path="DataContext.Length"></Binding>
- <Binding RelativeSource="{RelativeSource AncestorType=ItemsControl}" Path="ActualWidth"></Binding>
- <Binding Path="LengthWithFactor"></Binding>
- </MultiBinding>
- </Grid.Width>
- <Rectangle Fill="{Binding SegmentBrush}"></Rectangle>
- </Grid>
- </DataTemplate>
- </ItemsControl.ItemTemplate>
- </ItemsControl>
-
- <Rectangle Stroke="{StaticResource GrayBrush}" StrokeThickness="1" StrokeDashArray="5 5 5 5" RadiusX="8" RadiusY="8" />
- </Grid>
- </Border>
- </Grid>
-
- <Grid Grid.Column="1" VerticalAlignment="Bottom">
- <Grid.Style>
- <Style TargetType="Grid">
- <Setter Property="Visibility" Value="Collapsed"></Setter>
- <Style.Triggers>
- <MultiDataTrigger>
- <MultiDataTrigger.Conditions>
- <Condition Binding="{Binding JobType}" Value="{x:Static enumerations:JobTypes.Embroidery}" />
- <Condition Binding="{Binding ElementName=control,Path=IsActive}" Value="False" />
- </MultiDataTrigger.Conditions>
- <Setter Property="Visibility" Value="Visible"></Setter>
- </MultiDataTrigger>
- </Style.Triggers>
- </Style>
- </Grid.Style>
-
- <TextBlock Margin="10 0 0 -2" VerticalAlignment="Center" FontSize="16">
- <Run Text="x"></Run><Run Text="{Binding NumberOfUnits}"></Run>
- </TextBlock>
- </Grid>
- </Grid>
-</UserControl>
diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Controls/JobSummeryViewer.xaml.cs b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Controls/JobSummeryViewer.xaml.cs
deleted file mode 100644
index daa0d30cf..000000000
--- a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Controls/JobSummeryViewer.xaml.cs
+++ /dev/null
@@ -1,56 +0,0 @@
-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.Entities;
-
-namespace Tango.MachineStudio.Developer.Controls
-{
- /// <summary>
- /// Represents a <see cref="Job"/> summary viewer control.
- /// </summary>
- /// <seealso cref="System.Windows.Controls.UserControl" />
- /// <seealso cref="System.Windows.Markup.IComponentConnector" />
- public partial class JobSummeryViewer : UserControl
- {
- /// <summary>
- /// Maybe not necessary!
- /// </summary>
- public bool IsActive
- {
- get { return (bool)GetValue(IsActiveProperty); }
- set { SetValue(IsActiveProperty, value); }
- }
- public static readonly DependencyProperty IsActiveProperty =
- DependencyProperty.Register("IsActive", typeof(bool), typeof(JobSummeryViewer), new PropertyMetadata(false));
-
- /// <summary>
- /// Gets or sets a value indicating whether to display summery markers.
- /// </summary>
- public bool DisplayMarkers
- {
- get { return (bool)GetValue(DisplayMarkersProperty); }
- set { SetValue(DisplayMarkersProperty, value); }
- }
- public static readonly DependencyProperty DisplayMarkersProperty =
- DependencyProperty.Register("DisplayMarkers", typeof(bool), typeof(JobSummeryViewer), new PropertyMetadata(true));
-
- /// <summary>
- /// Initializes a new instance of the <see cref="JobSummeryViewer"/> class.
- /// </summary>
- public JobSummeryViewer()
- {
- InitializeComponent();
- }
- }
-}
diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Tango.MachineStudio.Developer.csproj b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Tango.MachineStudio.Developer.csproj
index 3853e6763..012ed8d0d 100644
--- a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Tango.MachineStudio.Developer.csproj
+++ b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Tango.MachineStudio.Developer.csproj
@@ -103,9 +103,6 @@
<Link>GlobalVersionInfo.cs</Link>
</Compile>
<Compile Include="Controls\JobOutlineControl.cs" />
- <Compile Include="Controls\JobSummeryViewer.xaml.cs">
- <DependentUpon>JobSummeryViewer.xaml</DependentUpon>
- </Compile>
<Compile Include="Converters\BrushStopLabToColorConverter.cs" />
<Compile Include="Converters\BrushStopCMYKToColorConverter.cs" />
<Compile Include="Converters\BrushStopToColorConverter.cs" />
@@ -161,10 +158,6 @@
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
- <Page Include="Controls\JobSummeryViewer.xaml">
- <Generator>MSBuild:Compile</Generator>
- <SubType>Designer</SubType>
- </Page>
<Page Include="Views\EmbroideryDisplayView.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
@@ -393,7 +386,7 @@
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<ProjectExtensions>
<VisualStudio>
- <UserProperties BuildVersion_StartDate="2000/1/1" BuildVersion_UseGlobalSettings="False" BuildVersion_BuildVersioningStyle="None.None.Increment.TimeStamp" BuildVersion_UpdateAssemblyVersion="True" BuildVersion_AssemblyInfoFilename="Properties\AssemblyInfo.cs" />
+ <UserProperties BuildVersion_AssemblyInfoFilename="Properties\AssemblyInfo.cs" BuildVersion_UpdateAssemblyVersion="True" BuildVersion_BuildVersioningStyle="None.None.Increment.TimeStamp" BuildVersion_UseGlobalSettings="False" BuildVersion_StartDate="2000/1/1" />
</VisualStudio>
</ProjectExtensions>
</Project> \ No newline at end of file
diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/ViewModels/MainViewVM.cs b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/ViewModels/MainViewVM.cs
index 4cc41e5a7..fc0680d9c 100644
--- a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/ViewModels/MainViewVM.cs
+++ b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/ViewModels/MainViewVM.cs
@@ -91,7 +91,6 @@ namespace Tango.MachineStudio.Developer.ViewModels
private JobDTO _beforeSaveJobDTO;
private IActionLogManager _actionLogManager;
private RmlDTO _selectedRMLBeforeLiquidFactorsSaves;
- private List<Cct> _cctCache;
#region Properties
@@ -758,8 +757,6 @@ namespace Tango.MachineStudio.Developer.ViewModels
{
_converter = new DefaultColorConverter();
- _cctCache = new List<Cct>();
-
CanWork = true;
EnableColorConversion = true;
@@ -1625,7 +1622,7 @@ namespace Tango.MachineStudio.Developer.ViewModels
{
LogManager.Log("Invalidating liquid factors, process parameters and process group history...");
- _selectedRML = new RmlBuilder(_activeJobDbContext).Set(SelectedRML).WithAllParametersGroup().WithCAT(SelectedMachine.Guid).WithCctCache(_cctCache).WithCCT().WithLiquidFactors().WithSpools().Build();
+ _selectedRML = new RmlBuilder(_activeJobDbContext).Set(SelectedRML.Guid).WithAllParametersGroup().WithCAT(SelectedMachine.Guid).WithCCT().WithLiquidFactors().WithSpools().Build();
_selectedRMLBeforeLiquidFactorsSaves = RmlDTO.FromObservable(_selectedRML);
@@ -1682,7 +1679,7 @@ namespace Tango.MachineStudio.Developer.ViewModels
InvalidateLiquidFactorsAndProcessTables();
}
catch
- { }
+ {}
finally
{
IsFree = true;
@@ -1870,7 +1867,7 @@ namespace Tango.MachineStudio.Developer.ViewModels
_activeJobDbContext.Spools.Where(x => x.MachineGuid == SelectedMachine.Guid).Load();
LogManager.Log("Setting active job...");
- ActiveJob = new JobBuilder(_activeJobDbContext).Set(SelectedMachineJob.Guid).WithUser().WithSegments().WithBrushStops().WithConfiguration().WithRML(_cctCache).Build();
+ ActiveJob = new JobBuilder(_activeJobDbContext).Set(SelectedMachineJob.Guid).WithUser().WithSegments().WithBrushStops().WithConfiguration().WithRML().Build();
//_activeJobDbContext.Ccts.Where(x => x.RmlGuid == ActiveJob.RmlGuid).ToList();
//_activeJobDbContext.Cats.Where(x => x.RmlGuid == ActiveJob.RmlGuid).ToList();
@@ -2335,7 +2332,7 @@ namespace Tango.MachineStudio.Developer.ViewModels
}
SelectedSegment.BrushStops.Remove(x);
var existingBrushStop = _activeJobDbContext.BrushStops.FirstOrDefault(y => y.Guid == x.Guid);
- if (existingBrushStop != null)
+ if(existingBrushStop != null)
{
_activeJobDbContext.BrushStops.Remove(existingBrushStop);
}
@@ -2375,7 +2372,7 @@ namespace Tango.MachineStudio.Developer.ViewModels
stop.SetAllDispensingStepDivisions(BL.Dispensing.DispenserStepDivisions.D8);
stop.SetLiquidVolumes(SelectedMachine.Configuration, SelectedRML, SelectedProcessParametersTable);
SelectedSegment.BrushStops.Add(stop);
- // _activeJobDbContext.BrushStops.Add(stop);
+ // _activeJobDbContext.BrushStops.Add(stop);
SelectedSegment.BrushStops.ToList().ForEach(x => x.RaiseOffsetChanged());
ArrangeBrushStopsIndices();
}
diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Views/JobView.xaml b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Views/JobView.xaml
index 395809c6f..32b7ccd86 100644
--- a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Views/JobView.xaml
+++ b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Views/JobView.xaml
@@ -27,7 +27,6 @@
xmlns:shapes="clr-namespace:Tango.SharedUI.Shapes;assembly=Tango.SharedUI"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:local="clr-namespace:Tango.MachineStudio.Developer.Views"
- xmlns:localControls="clr-namespace:Tango.MachineStudio.Developer.Controls"
mc:Ignorable="d"
d:DesignHeight="1080" d:DesignWidth="1920" Background="Transparent" d:DataContext="{d:DesignInstance Type=vm:MainViewVM, IsDesignTimeCreatable=False}"
DataContext="{x:Static global:ViewModelLocator.MainViewVM}" x:Name="control">
@@ -1321,9 +1320,78 @@
</Button>
</Grid>
- <Grid Margin="0 -5 0 0">
+ <Grid Margin="0 -18 0 0">
<Border VerticalAlignment="Center" Height="55" Margin="30 0 40 0" ClipToBounds="False">
- <localControls:JobSummeryViewer DataContext="{Binding ActiveJob}" />
+ <Grid ClipToBounds="False">
+ <ItemsControl x:Name="jobBrushList" ClipToBounds="False" Margin="40 0 50 0">
+ <ItemsControl.ItemsPanel>
+ <ItemsPanelTemplate>
+ <StackPanel Orientation="Horizontal" ClipToBounds="False"></StackPanel>
+ </ItemsPanelTemplate>
+ </ItemsControl.ItemsPanel>
+ <ItemsControl.ItemTemplate>
+ <DataTemplate>
+ <Grid>
+ <Grid.Width>
+ <MultiBinding Converter="{StaticResource SegmentLengthToWidthConverter}">
+ <Binding RelativeSource="{RelativeSource AncestorType=UserControl}" Path="DataContext.ActiveJob.Length"></Binding>
+ <Binding RelativeSource="{RelativeSource AncestorType=ItemsControl}" Path="ActualWidth"></Binding>
+ <Binding Path="Length"></Binding>
+ </MultiBinding>
+ </Grid.Width>
+ <Rectangle VerticalAlignment="Bottom" Height="20">
+ <Rectangle.Fill>
+ <MultiBinding Converter="{StaticResource SegmentToBrushConverterMulti}">
+ <Binding Path="."></Binding>
+ <Binding RelativeSource="{RelativeSource AncestorType=UserControl}" Path="DataContext.ActiveJob"></Binding>
+ <Binding RelativeSource="{RelativeSource AncestorType=UserControl}" Path="DataContext.ActiveJob.Length"></Binding>
+ <Binding RelativeSource="{RelativeSource AncestorType=UserControl}" Path="DataContext.SelectedBrushStop.Color"></Binding>
+ </MultiBinding>
+ </Rectangle.Fill>
+ </Rectangle>
+
+ <StackPanel Margin="0 0 0 0" HorizontalAlignment="Center">
+ <TextBlock FontSize="12" HorizontalAlignment="Right" Foreground="{StaticResource BlackForegroundBrush}">
+ <Run Text="{Binding Length,Mode=OneWay,StringFormat=N2}"></Run>
+ <Run Foreground="{StaticResource GrayBrush250}" FontSize="10" Text="m"></Run>
+ </TextBlock>
+ <materialDesign:PackIcon HorizontalAlignment="Center" RenderTransformOrigin="0.5,0.5" Kind="Triangle" Width="8" Height="8" Foreground="{StaticResource DimGrayBrush}">
+ <materialDesign:PackIcon.RenderTransform>
+ <RotateTransform Angle="180" />
+ </materialDesign:PackIcon.RenderTransform>
+ </materialDesign:PackIcon>
+ </StackPanel>
+ </Grid>
+ </DataTemplate>
+ </ItemsControl.ItemTemplate>
+ </ItemsControl>
+
+ <StackPanel Margin="-30 -5 0 0" HorizontalAlignment="Left">
+ <TextBlock FontSize="12" Foreground="{StaticResource BlackForegroundBrush}">
+ <Run Text="0"></Run>
+ <Run Foreground="{StaticResource GrayBrush250}" FontSize="10" Text="m"></Run>
+ </TextBlock>
+ <materialDesign:PackIcon HorizontalAlignment="Right" RenderTransformOrigin="0.5,0.5" Kind="SubdirectoryArrowRight" Width="16" Height="16" Foreground="{StaticResource DimGrayBrush}">
+
+ </materialDesign:PackIcon>
+ </StackPanel>
+
+ <StackPanel Margin="0 -5 -20 0" HorizontalAlignment="Right">
+ <TextBlock FontSize="12" Foreground="{StaticResource BlackForegroundBrush}">
+ <Run Text="{Binding ActiveJob.Length,Mode=OneWay,StringFormat=N2}"></Run>
+ <Run Foreground="Gray" FontSize="10" Text="m"></Run>
+ <Run>x</Run>
+ <Run Text="{Binding ActiveJob.NumberOfUnits}"></Run>
+ </TextBlock>
+ <materialDesign:PackIcon HorizontalAlignment="Right" RenderTransformOrigin="0.5,0.5" Kind="FlagCheckered" Width="16" Height="16" Foreground="{StaticResource DimGrayBrush}">
+
+ </materialDesign:PackIcon>
+ </StackPanel>
+
+ <Border BorderBrush="{StaticResource BorderBrushGainsboro}" BorderThickness="1" VerticalAlignment="Bottom" Height="20" Margin="40 0 50 0">
+
+ </Border>
+ </Grid>
</Border>
</Grid>
</DockPanel>
diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Views/JobView.xaml.cs b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Views/JobView.xaml.cs
index 6e9c62e74..94c1ed802 100644
--- a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Views/JobView.xaml.cs
+++ b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Views/JobView.xaml.cs
@@ -64,29 +64,29 @@ namespace Tango.MachineStudio.Developer.Views
{
if (_vm != null && _vm.ActiveJob != null)
{
- //List<Segment> segments = new List<Segment>();
- //foreach (var s in _vm.ActiveJob.OrderedSegments)
- //{
- // segments.Add(s);
+ List<Segment> segments = new List<Segment>();
+ foreach (var s in _vm.ActiveJob.OrderedSegments)
+ {
+ segments.Add(s);
- // if (_vm.ActiveJob.EnableInterSegment && _vm.ActiveJob.OrderedSegments.IndexOf(s) != _vm.ActiveJob.OrderedSegments.Count - 1)
- // {
- // segments.Add(new Segment()
- // {
- // Length = _vm.ActiveJob.InterSegmentLength,
- // BrushStops = new SynchronizedObservableCollection<BrushStop>()
- // {
- // new BrushStop()
- // {
- // ColorSpace = new ColorSpace(),
- // Color = Colors.White,
- // }
- // },
- // });
- // }
- //}
+ if (_vm.ActiveJob.EnableInterSegment && _vm.ActiveJob.OrderedSegments.IndexOf(s) != _vm.ActiveJob.OrderedSegments.Count - 1)
+ {
+ segments.Add(new Segment()
+ {
+ Length = _vm.ActiveJob.InterSegmentLength,
+ BrushStops = new SynchronizedObservableCollection<BrushStop>()
+ {
+ new BrushStop()
+ {
+ ColorSpace = new ColorSpace(),
+ Color = Colors.White,
+ }
+ },
+ });
+ }
+ }
- //jobBrushList.ItemsSource = segments;
+ jobBrushList.ItemsSource = segments;
UpdateGradientBrushDisplay();
}
}