|
|
|
|
@ -317,18 +317,26 @@ |
|
|
|
|
<Label Content="Protocol type:"/> |
|
|
|
|
<!-- ListBox with Protocol types--> |
|
|
|
|
<ListBox BorderBrush="Transparent" |
|
|
|
|
ItemsSource="{Binding Source={StaticResource ProtocolTypeValues}, Converter={StaticResource EnumValToDescConv}}" |
|
|
|
|
ItemsSource="{Binding Source={StaticResource ProtocolTypeValues}}" |
|
|
|
|
SelectionMode="Single" |
|
|
|
|
x:Name="listBoxStartMenuProtocols"> |
|
|
|
|
<ListBox.Resources> |
|
|
|
|
<Style TargetType="{x:Type ListBoxItem}"> |
|
|
|
|
<Setter Property="Template"> |
|
|
|
|
<Setter.Value> |
|
|
|
|
<ControlTemplate> |
|
|
|
|
<!-- Button Command binds with DataContext of parent ListBox, CommandParameter binds with the item --> |
|
|
|
|
<Button Margin="0 2" |
|
|
|
|
Content="{TemplateBinding ContentPresenter.Content}"> |
|
|
|
|
<!--Command="{Binding Path=DataContext.AppendTerminalWithSelectedViewTypeTestCommand, ElementName=listBoxStartMenuProtocols}" |
|
|
|
|
CommandParameter="{Binding Path=., Converter={helpers:Inverted {StaticResource EnumValToDescConv}}}">--> |
|
|
|
|
<Button Margin="0 2" Width="Auto" HorizontalContentAlignment="Stretch" |
|
|
|
|
Command="{Binding Path=Data.AppendTerminalWithSelectedViewTypeCommand, Source={StaticResource proxy}}" |
|
|
|
|
CommandParameter="{Binding Path=.}"> |
|
|
|
|
<DockPanel LastChildFill="False"> |
|
|
|
|
<Image DockPanel.Dock="Left" |
|
|
|
|
Height="17" Stretch="Fill" Margin="5 0 0 0" |
|
|
|
|
Source="{Binding Path=., Converter={StaticResource ProtocolTypeIconConverter}}" |
|
|
|
|
ToolTip="{Binding Path=., Converter={StaticResource EnumValToDescConv}}" |
|
|
|
|
ToolTipService.InitialShowDelay="200"/> |
|
|
|
|
<TextBlock DockPanel.Dock="Left" Margin="10 0 10 0" |
|
|
|
|
Text="{Binding Path=., Converter={StaticResource EnumValToDescConv}}"/> |
|
|
|
|
</DockPanel> |
|
|
|
|
</Button> |
|
|
|
|
</ControlTemplate> |
|
|
|
|
</Setter.Value> |
|
|
|
|
|