|
33 | 33 | <Grid.ColumnDefinitions> |
34 | 34 | <ColumnDefinition Width="Auto" /> |
35 | 35 | <ColumnDefinition Width="10" /> |
36 | | - <ColumnDefinition Width="*" /> |
| 36 | + <ColumnDefinition Width="200" /> |
37 | 37 | </Grid.ColumnDefinitions> |
38 | 38 | <Grid.RowDefinitions> |
39 | 39 | <RowDefinition Height="Auto" /> |
40 | 40 | <RowDefinition Height="10" /> |
41 | 41 | <RowDefinition Height="Auto" /> |
42 | 42 | <RowDefinition Height="10" /> |
43 | 43 | <RowDefinition Height="Auto" /> |
| 44 | + <RowDefinition Height="10" /> |
| 45 | + <RowDefinition Height="Auto" /> |
44 | 46 | </Grid.RowDefinitions> |
45 | | - <TextBlock Grid.Column="0" Grid.Row="0" Style="{StaticResource CenterTextBlock}" Text="{DynamicResource String_MACAddress}" /> |
| 47 | + <TextBlock Grid.Column="0" Grid.Row="0" Style="{StaticResource CenterTextBlock}" DataContext="{DynamicResource String_MACAddress}" Text="{Binding Path=., StringFormat={}{0}:}" /> |
46 | 48 | <TextBox Grid.Column="2" Grid.Row="0" x:Name="txtMACAddress" WpfHelper:ProtocolSettingsLayout.MVVMHasError="{Binding MACAddressHasError}" mah:TextBoxHelper.Watermark="{DynamicResource String_Watermark_ExampleMACAddress}" Style="{StaticResource DefaultTextBox}"> |
47 | 49 | <TextBox.InputBindings> |
48 | 50 | <KeyBinding Key="Enter" Command="{Binding WakeUpCommand}" /> |
|
56 | 58 | </Binding> |
57 | 59 | </TextBox.Text> |
58 | 60 | </TextBox> |
59 | | - <TextBlock Grid.Column="0" Grid.Row="2" Text="{DynamicResource String_Broadcast}" Style="{StaticResource CenterTextBlock}" /> |
| 61 | + <TextBlock Grid.Column="0" Grid.Row="2" DataContext="{DynamicResource String_Broadcast}" Text="{Binding Path=., StringFormat={}{0}:}" Style="{StaticResource CenterTextBlock}" /> |
60 | 62 | <TextBox x:Name="txtBroadcast" Grid.Column="2" Grid.Row="2" WpfHelper:ProtocolSettingsLayout.MVVMHasError="{Binding BroadcastHasError}" mah:TextBoxHelper.Watermark="{DynamicResource String_Watermark_ExampleIPv4Broadcast}" Style="{StaticResource DefaultTextBox}"> |
61 | 63 | <TextBox.InputBindings> |
62 | 64 | <KeyBinding Key="Enter" Command="{Binding WakeUpCommand}" /> |
|
70 | 72 | </Binding> |
71 | 73 | </TextBox.Text> |
72 | 74 | </TextBox> |
73 | | - <TextBlock Grid.Column="0" Grid.Row="4" Text="{DynamicResource String_Port}" Style="{StaticResource CenterTextBlock}" /> |
| 75 | + <TextBlock Grid.Column="0" Grid.Row="4" DataContext="{DynamicResource String_Port}" Text="{Binding Path=., StringFormat={}{0}:}" Style="{StaticResource CenterTextBlock}" /> |
74 | 76 | <TextBox x:Name="txtPort" Grid.Column="2" Grid.Row="4" WpfHelper:ProtocolSettingsLayout.MVVMHasError="{Binding PortHasError}" mah:TextBoxHelper.Watermark="{DynamicResource String_Watermark_ExamplePort}" Style="{StaticResource DefaultTextBox}" HorizontalAlignment="Left" Width="65" Validation.ErrorTemplate="{StaticResource DefaultErrorTemplate}"> |
75 | 77 | <TextBox.InputBindings> |
76 | 78 | <KeyBinding Key="Enter" Command="{Binding WakeUpCommand}" /> |
|
84 | 86 | </Binding> |
85 | 87 | </TextBox.Text> |
86 | 88 | </TextBox> |
| 89 | + <Button Grid.Column="2" Grid.Row="6" HorizontalAlignment="Right" Command="{Binding WakeUpCommand}"> |
| 90 | + <Button.Content> |
| 91 | + <Grid> |
| 92 | + <Grid.ColumnDefinitions> |
| 93 | + <ColumnDefinition Width="Auto" /> |
| 94 | + <ColumnDefinition Width="*" /> |
| 95 | + </Grid.ColumnDefinitions> |
| 96 | + <Rectangle Width="20" Height="20" Margin="10,5,0,5" Fill="{DynamicResource GrayBrush3}"> |
| 97 | + <Rectangle.OpacityMask> |
| 98 | + <VisualBrush Stretch="Uniform" Visual="{IconPacks:PackIconMaterial Kind=Power}" /> |
| 99 | + </Rectangle.OpacityMask> |
| 100 | + </Rectangle> |
| 101 | + <TextBlock Grid.Column="1" Text="{DynamicResource String_Button_WakeUp}" FontSize="14" Margin="10,5" TextAlignment="Center"/> |
| 102 | + </Grid> |
| 103 | + </Button.Content> |
| 104 | + <Button.Style> |
| 105 | + <Style TargetType="{x:Type Button}" BasedOn="{StaticResource ImageWithTextButton}" > |
| 106 | + <Setter Property="IsEnabled" Value="False" /> |
| 107 | + <Style.Triggers> |
| 108 | + <MultiDataTrigger> |
| 109 | + <MultiDataTrigger.Conditions> |
| 110 | + <Condition Binding="{Binding Path=(Validation.HasError), ElementName=txtMACAddress}" Value="False"/> |
| 111 | + <Condition Binding="{Binding Path=(Validation.HasError), ElementName=txtBroadcast}" Value="False"/> |
| 112 | + <Condition Binding="{Binding Path=(Validation.HasError), ElementName=txtPort}" Value="False"/> |
| 113 | + </MultiDataTrigger.Conditions> |
| 114 | + <Setter Property="IsEnabled" Value="True" /> |
| 115 | + </MultiDataTrigger> |
| 116 | + </Style.Triggers> |
| 117 | + </Style> |
| 118 | + </Button.Style> |
| 119 | + </Button> |
87 | 120 | </Grid> |
88 | | - <Button Grid.Row="2" HorizontalAlignment="Right" Command="{Binding WakeUpCommand}"> |
89 | | - <Button.Content> |
90 | | - <Grid> |
91 | | - <Grid.ColumnDefinitions> |
92 | | - <ColumnDefinition Width="Auto" /> |
93 | | - <ColumnDefinition Width="*" /> |
94 | | - </Grid.ColumnDefinitions> |
95 | | - <Rectangle Width="20" Height="20" Margin="10,5,0,5" Fill="{DynamicResource GrayBrush3}"> |
96 | | - <Rectangle.OpacityMask> |
97 | | - <VisualBrush Stretch="Uniform" Visual="{IconPacks:PackIconMaterial Kind=Power}" /> |
98 | | - </Rectangle.OpacityMask> |
99 | | - </Rectangle> |
100 | | - <TextBlock Grid.Column="1" Text="{DynamicResource String_Button_WakeUp}" FontSize="14" Margin="10,5" TextAlignment="Center"/> |
101 | | - </Grid> |
102 | | - </Button.Content> |
103 | | - <Button.Style> |
104 | | - <Style TargetType="{x:Type Button}" BasedOn="{StaticResource ImageWithTextButton}" > |
105 | | - <Setter Property="IsEnabled" Value="False" /> |
106 | | - <Style.Triggers> |
107 | | - <MultiDataTrigger> |
108 | | - <MultiDataTrigger.Conditions> |
109 | | - <Condition Binding="{Binding Path=(Validation.HasError), ElementName=txtMACAddress}" Value="False"/> |
110 | | - <Condition Binding="{Binding Path=(Validation.HasError), ElementName=txtBroadcast}" Value="False"/> |
111 | | - <Condition Binding="{Binding Path=(Validation.HasError), ElementName=txtPort}" Value="False"/> |
112 | | - </MultiDataTrigger.Conditions> |
113 | | - <Setter Property="IsEnabled" Value="True" /> |
114 | | - </MultiDataTrigger> |
115 | | - </Style.Triggers> |
116 | | - </Style> |
117 | | - </Button.Style> |
118 | | - </Button> |
119 | | - <TextBlock Grid.Row="3" Foreground="{DynamicResource AccentColorBrush}" Text="{Binding StatusMessage}" Visibility="{Binding DisplayStatusMessage, Converter={StaticResource BooleanToVisibilityConverter}}" Style="{DynamicResource DefaultTextBlock}" Margin="0,10,0,0" /> |
| 121 | + |
| 122 | + <TextBlock Grid.Row="2" Foreground="{DynamicResource AccentColorBrush}" Text="{Binding StatusMessage}" Visibility="{Binding DisplayStatusMessage, Converter={StaticResource BooleanToVisibilityConverter}}" Style="{DynamicResource DefaultTextBlock}" Margin="0,10,0,0" /> |
120 | 123 | </Grid> |
121 | 124 | <Border Grid.Column="1" Grid.Row="0" BorderThickness="1,0,0,0" BorderBrush="{DynamicResource GrayBrush8}"> |
122 | 125 | <Expander x:Name="expanderProfiles" Header="{DynamicResource String_Header_Clients}" Style="{StaticResource RightExpander}" IsExpanded="{Binding ExpandClientView}"> |
|
0 commit comments