aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/PPC/Tango.PPC.Common/Controls
diff options
context:
space:
mode:
authorRoy Ben-Shabat <Roy@Twine-s.com>2019-07-29 13:23:36 +0300
committerRoy Ben-Shabat <Roy@Twine-s.com>2019-07-29 13:23:36 +0300
commit1b7fb335900547edb4d9feb2314e607863e695d4 (patch)
tree8d923bd0ff6d6c6aa089523f2b5af69f9eab18d9 /Software/Visual_Studio/PPC/Tango.PPC.Common/Controls
parent230ea9b597a2932f5d16572d94ee14c862d5b419 (diff)
downloadTango-1b7fb335900547edb4d9feb2314e607863e695d4.tar.gz
Tango-1b7fb335900547edb4d9feb2314e607863e695d4.zip
Added ColorCatalogGuid to job.
Added catalog selection to job creation.
Diffstat (limited to 'Software/Visual_Studio/PPC/Tango.PPC.Common/Controls')
-rw-r--r--Software/Visual_Studio/PPC/Tango.PPC.Common/Controls/TwineCatalogControl.xaml2
-rw-r--r--Software/Visual_Studio/PPC/Tango.PPC.Common/Controls/TwineCatalogControl.xaml.cs12
2 files changed, 7 insertions, 7 deletions
diff --git a/Software/Visual_Studio/PPC/Tango.PPC.Common/Controls/TwineCatalogControl.xaml b/Software/Visual_Studio/PPC/Tango.PPC.Common/Controls/TwineCatalogControl.xaml
index 4d21de67e..c4d047d39 100644
--- a/Software/Visual_Studio/PPC/Tango.PPC.Common/Controls/TwineCatalogControl.xaml
+++ b/Software/Visual_Studio/PPC/Tango.PPC.Common/Controls/TwineCatalogControl.xaml
@@ -112,7 +112,7 @@
</RectangleGeometry.Rect>
</RectangleGeometry>
</Border.Clip>
- <ItemsControl ItemsSource="{Binding ColorCatalogsGroups}">
+ <ItemsControl ItemsSource="{Binding ColorCatalogsGroupsOrdered}">
<ItemsControl.ItemsPanel>
<ItemsPanelTemplate>
<UniformGrid Columns="1" />
diff --git a/Software/Visual_Studio/PPC/Tango.PPC.Common/Controls/TwineCatalogControl.xaml.cs b/Software/Visual_Studio/PPC/Tango.PPC.Common/Controls/TwineCatalogControl.xaml.cs
index 2f584740c..6ef7d92e8 100644
--- a/Software/Visual_Studio/PPC/Tango.PPC.Common/Controls/TwineCatalogControl.xaml.cs
+++ b/Software/Visual_Studio/PPC/Tango.PPC.Common/Controls/TwineCatalogControl.xaml.cs
@@ -56,7 +56,7 @@ namespace Tango.PPC.Common.Controls
{
scrollViewer.ScrollToTop();
_preventChange = true;
- slider.Value = _catalog.ColorCatalogsGroups.Count;
+ slider.Value = _catalog.ColorCatalogsGroupsOrdered.Count;
_preventChange = false;
}
};
@@ -80,7 +80,7 @@ namespace Tango.PPC.Common.Controls
if (group != null)
{
_preventChange = true;
- slider.Value = slider.Maximum - _catalog.ColorCatalogsGroups.IndexOf(group);
+ slider.Value = slider.Maximum - _catalog.ColorCatalogsGroupsOrdered.IndexOf(group);
_preventChange = false;
}
@@ -96,22 +96,22 @@ namespace Tango.PPC.Common.Controls
/// <param name="e">The <see cref="RoutedPropertyChangedEventArgs{System.Double}"/> instance containing the event data.</param>
private void TouchSlider_ValueChanged(object sender, RoutedPropertyChangedEventArgs<double> e)
{
- if (_catalog == null || _catalog.ColorCatalogsGroups.Count == 0) return;
+ if (_catalog == null || _catalog.ColorCatalogsGroupsOrdered.Count == 0) return;
if (!_preventChange)
{
if (_catalog != null)
{
_preventChange = true;
- var group = _catalog.ColorCatalogsGroups.ElementAt(_catalog.ColorCatalogsGroups.Count - 1 - (int)e.NewValue);
+ var group = _catalog.ColorCatalogsGroupsOrdered.ElementAt(_catalog.ColorCatalogsGroupsOrdered.Count - 1 - (int)e.NewValue);
scrollViewer.ScrollToPosition(renderer.GetGroupPosition(group));
_preventChange = false;
}
}
- if (_catalog != null && _catalog.ColorCatalogsGroups.Count > _catalog.ColorCatalogsGroups.Count - 1 - (int)e.NewValue && _catalog.ColorCatalogsGroups.Count - 1 - (int)e.NewValue > -1)
+ if (_catalog != null && _catalog.ColorCatalogsGroupsOrdered.Count > _catalog.ColorCatalogsGroupsOrdered.Count - 1 - (int)e.NewValue && _catalog.ColorCatalogsGroupsOrdered.Count - 1 - (int)e.NewValue > -1)
{
- slider.Foreground = new SolidColorBrush(_catalog.ColorCatalogsGroups.ElementAt(_catalog.ColorCatalogsGroups.Count - 1 - (int)e.NewValue).Color);
+ slider.Foreground = new SolidColorBrush(_catalog.ColorCatalogsGroupsOrdered.ElementAt(_catalog.ColorCatalogsGroupsOrdered.Count - 1 - (int)e.NewValue).Color);
}
}
}