|
|
|
@ -7,6 +7,7 @@ |
|
|
|
xmlns:local="clr-namespace:MultiTerm.Wpf.View.SettingsView" |
|
|
|
xmlns:local="clr-namespace:MultiTerm.Wpf.View.SettingsView" |
|
|
|
xmlns:conv="clr-namespace:MultiTerm.Wpf.ValueConverters" |
|
|
|
xmlns:conv="clr-namespace:MultiTerm.Wpf.ValueConverters" |
|
|
|
xmlns:serial_protocol="clr-namespace:MultiTerm.Protocols.Serial;assembly=MultiTerm.Protocols" |
|
|
|
xmlns:serial_protocol="clr-namespace:MultiTerm.Protocols.Serial;assembly=MultiTerm.Protocols" |
|
|
|
|
|
|
|
xmlns:XamlBehavioursWpf="http://schemas.microsoft.com/xaml/behaviors" |
|
|
|
mc:Ignorable="d" |
|
|
|
mc:Ignorable="d" |
|
|
|
d:DesignHeight="50" d:DesignWidth="800"> |
|
|
|
d:DesignHeight="50" d:DesignWidth="800"> |
|
|
|
<DockPanel> |
|
|
|
<DockPanel> |
|
|
|
@ -43,16 +44,39 @@ |
|
|
|
</StackPanel.Resources> |
|
|
|
</StackPanel.Resources> |
|
|
|
|
|
|
|
|
|
|
|
<Label Margin="10 0" VerticalAlignment="Center">Port: </Label> |
|
|
|
<Label Margin="10 0" VerticalAlignment="Center">Port: </Label> |
|
|
|
<ComboBox Width="100" ItemsSource="{Binding Path=ComPorts}" SelectedItem="{Binding Path=PortName, Mode=TwoWay}" |
|
|
|
<ComboBox Width="100" x:Name="comboBoxPorts" |
|
|
|
VerticalContentAlignment="Center"/> |
|
|
|
ItemsSource="{Binding Path=ComPorts}" SelectedItem="{Binding Path=PortName, Mode=TwoWay}" |
|
|
|
|
|
|
|
VerticalContentAlignment="Center"> |
|
|
|
|
|
|
|
<!-- Auto reload com ports when opening combobox --> |
|
|
|
|
|
|
|
<XamlBehavioursWpf:Interaction.Triggers> |
|
|
|
|
|
|
|
<XamlBehavioursWpf:EventTrigger EventName="DropDownOpened" SourceObject="{Binding ElementName=comboBoxPorts}"> |
|
|
|
|
|
|
|
<XamlBehavioursWpf:InvokeCommandAction Command="{Binding ReloadComPortsCommand}" /> |
|
|
|
|
|
|
|
</XamlBehavioursWpf:EventTrigger> |
|
|
|
|
|
|
|
</XamlBehavioursWpf:Interaction.Triggers> |
|
|
|
|
|
|
|
</ComboBox> |
|
|
|
<Button Margin="5 0" Content="R" VerticalContentAlignment="Center" |
|
|
|
<Button Margin="5 0" Content="R" VerticalContentAlignment="Center" |
|
|
|
Command="{Binding ReloadComPortsCommand}" Width="25"/> |
|
|
|
Command="{Binding ReloadComPortsCommand}" Width="25"/> |
|
|
|
|
|
|
|
|
|
|
|
<Label Margin="20 0 10 0" VerticalAlignment="Center">Baud Rate:</Label> |
|
|
|
<Label Margin="20 0 10 0" VerticalAlignment="Center">Baud Rate:</Label> |
|
|
|
<TextBox Width="100" VerticalContentAlignment="Center" Text="{Binding Path=BaudRate, Converter={StaticResource IntToStringConverter}, Mode=TwoWay}" /> |
|
|
|
<ComboBox IsEditable="True" Width="100" VerticalContentAlignment="Center" Text="{Binding Path=BaudRate, Converter={StaticResource IntToStringConverter}, Mode=TwoWay}" > |
|
|
|
|
|
|
|
<ComboBoxItem Content="2400"/> |
|
|
|
|
|
|
|
<ComboBoxItem Content="9600"/> |
|
|
|
|
|
|
|
<ComboBoxItem Content="19200"/> |
|
|
|
|
|
|
|
<ComboBoxItem Content="56000"/> |
|
|
|
|
|
|
|
<ComboBoxItem Content="57600"/> |
|
|
|
|
|
|
|
<ComboBoxItem Content="115200"/> |
|
|
|
|
|
|
|
<ComboBoxItem Content="128000"/> |
|
|
|
|
|
|
|
<ComboBoxItem Content="256000"/> |
|
|
|
|
|
|
|
</ComboBox> |
|
|
|
|
|
|
|
|
|
|
|
<Label Margin="10 0 10 0" VerticalAlignment="Center">Data Bits:</Label> |
|
|
|
<Label Margin="10 0 10 0" VerticalAlignment="Center">Data Bits:</Label> |
|
|
|
<TextBox Width="40" VerticalContentAlignment="Center" Text="{Binding Path=DataBits, Converter={StaticResource IntToStringConverter}, Mode=TwoWay}" /> |
|
|
|
<ComboBox IsEditable="False" Width="Auto" VerticalContentAlignment="Center" Text="{Binding Path=DataBits, Converter={StaticResource IntToStringConverter}, Mode=TwoWay}" > |
|
|
|
|
|
|
|
<ComboBoxItem Content="5"/> |
|
|
|
|
|
|
|
<ComboBoxItem Content="6"/> |
|
|
|
|
|
|
|
<ComboBoxItem Content="7"/> |
|
|
|
|
|
|
|
<ComboBoxItem Content="8"/> |
|
|
|
|
|
|
|
<ComboBoxItem Content="16"/> |
|
|
|
|
|
|
|
</ComboBox> |
|
|
|
|
|
|
|
|
|
|
|
<Label Margin="10 0 10 0" VerticalAlignment="Center">Parity:</Label> |
|
|
|
<Label Margin="10 0 10 0" VerticalAlignment="Center">Parity:</Label> |
|
|
|
<ComboBox Width="Auto" VerticalContentAlignment="Center" |
|
|
|
<ComboBox Width="Auto" VerticalContentAlignment="Center" |
|
|
|
|