aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/PPC/Modules
diff options
context:
space:
mode:
Diffstat (limited to 'Software/Visual_Studio/PPC/Modules')
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/AdvancedColorCorrectionView.xaml25
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/JobViewVM.cs21
-rw-r--r--Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobView.xaml1
3 files changed, 34 insertions, 13 deletions
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/AdvancedColorCorrectionView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/AdvancedColorCorrectionView.xaml
index defd65d6e..abe2fab7d 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/AdvancedColorCorrectionView.xaml
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Dialogs/AdvancedColorCorrectionView.xaml
@@ -42,10 +42,35 @@
<Image Source="../Images/JobView/error.png" Stretch="None" Visibility="{Binding IsOutOfGamut,Converter={StaticResource BooleanToVisibilityConverter}}" />
<Ellipse Width="60" Height="60" Margin="20 0 0 0" Fill="{Binding InvalidBrushStop.Brush}" />
<TextBlock VerticalAlignment="Center" Foreground="{StaticResource TangoGrayTextBrush}" Margin="20 0 0 0">
+ <TextBlock.Style>
+ <Style TargetType="TextBlock">
+ <Setter Property="Visibility" Value="Collapsed"></Setter>
+ <Style.Triggers>
+ <DataTrigger Binding="{Binding InvalidBrushStop.BrushColorSpace}" Value="RGB">
+ <Setter Property="Visibility" Value="Visible"></Setter>
+ </DataTrigger>
+ </Style.Triggers>
+ </Style>
+ </TextBlock.Style>
<Run Text="{Binding InvalidBrushStop.Red}"></Run><Run>,</Run>
<Run Text="{Binding InvalidBrushStop.Green}"></Run><Run>,</Run>
<Run Text="{Binding InvalidBrushStop.Blue}"></Run>
</TextBlock>
+ <TextBlock VerticalAlignment="Center" Foreground="{StaticResource TangoGrayTextBrush}" Margin="20 0 0 0">
+ <TextBlock.Style>
+ <Style TargetType="TextBlock">
+ <Setter Property="Visibility" Value="Collapsed"></Setter>
+ <Style.Triggers>
+ <DataTrigger Binding="{Binding InvalidBrushStop.BrushColorSpace}" Value="LAB">
+ <Setter Property="Visibility" Value="Visible"></Setter>
+ </DataTrigger>
+ </Style.Triggers>
+ </Style>
+ </TextBlock.Style>
+ <Run Text="{Binding InvalidBrushStop.L,StringFormat=0.00}"></Run><Run>,</Run>
+ <Run Text="{Binding InvalidBrushStop.A,StringFormat=0.00}"></Run><Run>,</Run>
+ <Run Text="{Binding InvalidBrushStop.B,StringFormat=0.00}"></Run>
+ </TextBlock>
</StackPanel>
<DockPanel Grid.Row="2" Margin="0 0 0 0">
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/JobViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/JobViewVM.cs
index f07c20aa9..c394bbfa1 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/JobViewVM.cs
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/ViewModels/JobViewVM.cs
@@ -760,15 +760,8 @@ namespace Tango.PPC.Jobs.ViewModels
{
draggedSegment.SegmentIndex = droppedSegment.SegmentIndex + 1;
}
-
- int index = 1;
-
- foreach (var segment in Job.Segments.OrderBy(x => x.SegmentIndex))
- {
- segment.SegmentIndex = index++;
- }
-
- SegmentsCollectionView.Refresh();
+
+ ArrangeSegmentsIndices();
}
/// <summary>
@@ -831,10 +824,14 @@ namespace Tango.PPC.Jobs.ViewModels
private void ArrangeSegmentsIndices()
{
- for (int i = 0; i < Job.Segments.Count; i++)
+ int index = 1;
+
+ foreach (var segment in Job.Segments.OrderBy(x => x.SegmentIndex))
{
- Job.Segments[i].SegmentIndex = i + 1;
+ segment.SegmentIndex = index++;
}
+
+ SegmentsCollectionView.Refresh();
}
#endregion
@@ -982,7 +979,7 @@ namespace Tango.PPC.Jobs.ViewModels
[HandleProcessCorruptedStateExceptions]
public void OnBrushStopFieldValueChanged(BrushStop stop)
{
- if (stop != null)
+ if (stop != null && stop.ColorSpace != null)
{
stop.Corrected = false;
stop.OutOfGamutChecked = false;
diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobView.xaml
index c04c13ea1..557576d22 100644
--- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobView.xaml
+++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Jobs/Views/JobView.xaml
@@ -631,7 +631,6 @@
<touch:TouchToggleImageButton x:Name="toggleEdit" UncheckedImage="../Images/pencil-gray.png"
CheckedImage="../Images/pencil-blue.png"
DockPanel.Dock="Right"
- IsChecked="{Binding IsSelected}"
Padding="8" CornerRadius="30" Width="40" Height="40">
</touch:TouchToggleImageButton>
<!--<touch:TouchToggleIconButton x:Name="toggleEdit" DockPanel.Dock="Right" Icon="Pencil" CheckedIcon="Pencil" Padding="8" CornerRadius="20" />-->