aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer
diff options
context:
space:
mode:
Diffstat (limited to 'Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer')
-rw-r--r--Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Views/JobView.xaml4
-rw-r--r--Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.Developer/Views/JobView.xaml.cs11
2 files changed, 13 insertions, 2 deletions
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 884f60875..9151cbaa0 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
@@ -311,7 +311,7 @@
</StackPanel>
</Border>
- <controls:MultiSelectListBox x:Name="listBoxSegments" AutomationProperties.AutomationId="{x:Static automation:Developer.SegmentsListBox}" Style="{StaticResource {x:Type ListBox}}" SelectionMode="Extended" SelectionChanged="ListBox_SelectionChanged" ItemsSource="{Binding SegmentsCollectionView}" SelectedItem="{Binding SelectedSegment}" SelectedItemsList="{Binding SelectedSegments,Mode=TwoWay}" HorizontalContentAlignment="Stretch">
+ <controls:MultiSelectListBox FocusVisualStyle="{x:Null}" x:Name="listBoxSegments" MouseEnter="listBoxSegments_MouseEnter" PreviewMouseDown="listBoxSegments_PreviewMouseDown" AutomationProperties.AutomationId="{x:Static automation:Developer.SegmentsListBox}" Style="{StaticResource {x:Type ListBox}}" SelectionMode="Extended" SelectionChanged="ListBox_SelectionChanged" ItemsSource="{Binding SegmentsCollectionView}" SelectedItem="{Binding SelectedSegment}" SelectedItemsList="{Binding SelectedSegments,Mode=TwoWay}" HorizontalContentAlignment="Stretch">
<ListBox.ItemContainerStyle>
<Style TargetType="ListBoxItem" BasedOn="{StaticResource basicListBoxItem}">
<EventSetter Event="PreviewMouseDown" Handler="ListBoxItem_PreviewMouseDown"></EventSetter>
@@ -555,7 +555,7 @@
<Image Source="../Images/ruler.png" Width="32"></Image>
<TextBlock VerticalAlignment="Center" Margin="5 0 0 0" FontSize="10">Segment Length</TextBlock>
</StackPanel>
- <mahapps:NumericUpDown FontSize="{StaticResource NumbersFontSize}" HideUpDownButtons="True" Width="90" HorizontalAlignment="Left" FontFamily="{StaticResource digital-7}" StringFormat="{}{0:N1} m" Margin="0 2 0 0" Minimum="1" Maximum="10000" InterceptArrowKeys="True" Background="Transparent" BorderThickness="0 0 0 1" BorderBrush="DimGray" InterceptMouseWheel="True" HasDecimals="True" HorizontalContentAlignment="Left" Value="{Binding SelectedSegment.Length,Mode=TwoWay}"></mahapps:NumericUpDown>
+ <mahapps:NumericUpDown x:Name="numSegmentLength" FontSize="{StaticResource NumbersFontSize}" HideUpDownButtons="True" Width="90" HorizontalAlignment="Left" FontFamily="{StaticResource digital-7}" StringFormat="{}{0:N1} m" Margin="0 2 0 0" Minimum="1" Maximum="10000" InterceptArrowKeys="True" Background="Transparent" BorderThickness="0 0 0 1" BorderBrush="DimGray" InterceptMouseWheel="True" HasDecimals="True" HorizontalContentAlignment="Left" Value="{Binding SelectedSegment.Length,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"></mahapps:NumericUpDown>
</StackPanel>
</Border>
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 f7e2e8260..d96f130ae 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
@@ -281,5 +281,16 @@ namespace Tango.MachineStudio.Developer.Views
{
listBoxSegments.SelectedItem = (sender as ListBoxItem).DataContext;
}
+
+ private void listBoxSegments_PreviewMouseDown(object sender, MouseButtonEventArgs e)
+ {
+
+ }
+
+ private void listBoxSegments_MouseEnter(object sender, MouseEventArgs e)
+ {
+ Keyboard.ClearFocus();
+ listBoxSegments.Focus();
+ }
}
}